PHPackages                             sorted-list/sorted-list - 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. sorted-list/sorted-list

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

sorted-list/sorted-list
=======================

The package provides sorted list class.

1.1.0(1y ago)0209proprietaryPHPPHP ^7.4|^8.0

Since Nov 1Pushed 1y ago1 watchersCompare

[ Source](https://github.com/dmitrik86/sorted-list)[ Packagist](https://packagist.org/packages/sorted-list/sorted-list)[ RSS](/packages/sorted-list-sorted-list/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (1)Versions (5)Used By (0)

Sorted list
===========

[](#sorted-list)

The package provides sorted list class with methods to work with sorted list.

How to install
==============

[](#how-to-install)

Add the package

```
composer require sorted-list/sorted-list

```

How to use
==========

[](#how-to-use)

Create a class `SortedList`

```
use SortedList\SortedList;

$sortedList = new SortedList();

```

Methods
=======

[](#methods)

1. Add new value to sorted list

```
$sortedList->put($value);

```

2. Get sorted list

```
$sortedList->get();

```

3. Check if value exists in sorted list

```
$sortedList->exists($value);

```

4. Get leftmost position of new value

```
$sortedList->leftPosition($value);

```

5. Get rightmost position of new value

```
$sortedList->rightPosition($value);

```

6. Get minimum and maximum value respectively

```
$sortedList->getMin();
$sortedList->getMax();

```

7. Extract minimum and maximum value respectively

```
$sortedList->popMin();
$sortedList->popMax();

```

Unit tests
==========

[](#unit-tests)

1. Install unit test package

```
composer install --dev

```

2. Run unit tests

```
./vendor/bin/phpunit

```

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance36

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity51

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

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 ~112 days

Total

4

Last Release

593d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/b2f568f6c9c3a48b6d94bab941a92810d5550cd066d154db2ef513b9b1fa943c?d=identicon)[dmitrik86](/maintainers/dmitrik86)

---

Top Contributors

[![dmitrik86](https://avatars.githubusercontent.com/u/13481872?v=4)](https://github.com/dmitrik86 "dmitrik86 (6 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/sorted-list-sorted-list/health.svg)

```
[![Health](https://phpackages.com/badges/sorted-list-sorted-list/health.svg)](https://phpackages.com/packages/sorted-list-sorted-list)
```

PHPackages © 2026

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