PHPackages                             s9e/shortest-common-superstring - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. s9e/shortest-common-superstring

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

s9e/shortest-common-superstring
===============================

Shortest common superstring generator

2.1.0(6y ago)018MITPHP &gt;=7.1

Since Dec 19Compare

[ Source](https://github.com/s9e/ShortestCommonSuperstring)[ Packagist](https://packagist.org/packages/s9e/shortest-common-superstring)[ Docs](https://github.com/s9e/ShortestCommonSuperstring/)[ RSS](/packages/s9e-shortest-common-superstring/feed)WikiDiscussions Synced today

READMEChangelog (7)Dependencies (1)Versions (11)Used By (0)

s9e\\ShortestCommonSuperstring takes a list of strings and returns a single string that contains all of the given input. The implementation uses a greedy approximation algorithm.

[![Build Status](https://camo.githubusercontent.com/4920b78946c6e54e99edeb51cda281ba961aaad5906396ca5375e49851ffca9c/68747470733a2f2f6170692e7472617669732d63692e6f72672f7339652f53686f7274657374436f6d6d6f6e5375706572737472696e672e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/s9e/ShortestCommonSuperstring)[![Code Coverage](https://camo.githubusercontent.com/b977f28c915f5a179cf8ca700b1e94d1df1ed28f25da27c056f3239695384d8d/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f7339652f53686f7274657374436f6d6d6f6e5375706572737472696e672f6261646765732f636f7665726167652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/s9e/ShortestCommonSuperstring/?branch=master)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/0e2d9ce85ec9caebad15e90813b6add1812d2bb4ee405efbf4003a6f6e9d4a29/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f7339652f53686f7274657374436f6d6d6f6e5375706572737472696e672f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/s9e/ShortestCommonSuperstring/?branch=master)

Usage
-----

[](#usage)

```
$scs = new s9e\ShortestCommonSuperstring\ShortestCommonSuperstring;
echo $scs->getShortest(['abb', 'bba', 'bbb']);
```

```
abbba

```

###  Health Score

26

—

LowBetter than 41% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community2

Small or concentrated contributor base

Maturity64

Established project with proven stability

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~150 days

Recently: every ~0 days

Total

8

Last Release

2429d ago

Major Versions

1.1.1 → 2.0.02019-11-03

PHP version history (2 changes)1.0.0PHP &gt;=5.4.0

2.0.0PHP &gt;=7.1

### Community

Maintainers

![](https://www.gravatar.com/avatar/06ce60f935a636cbb13d7ca4733fa28c9a2c9d500834c6481f86e05fd4a55e86?d=identicon)[s9e](/maintainers/s9e)

---

Tags

scssuperstringsupersequence

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/s9e-shortest-common-superstring/health.svg)

```
[![Health](https://phpackages.com/badges/s9e-shortest-common-superstring/health.svg)](https://phpackages.com/packages/s9e-shortest-common-superstring)
```

###  Alternatives

[symfony/polyfill-php70

Symfony polyfill backporting some PHP 7.0+ features to lower PHP versions

3.2k201.6M59](/packages/symfony-polyfill-php70)[tomnomnom/etherpad-lite-client

Etherpad Lite client for PHP

8946.2k](/packages/tomnomnom-etherpad-lite-client)[ourcodeworld/name-that-color

A non-official PHP port of the NTC JS library to find out the name of the closest matching color.

35193.2k](/packages/ourcodeworld-name-that-color)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
