2017 © Pedro Peláez
 

library bitmaskgenerator

Generates all possible bitmasks with a minimum amount of positives (1's) and a certain length.

image

jelle-s/bitmaskgenerator

Generates all possible bitmasks with a minimum amount of positives (1's) and a certain length.

  • Wednesday, January 11, 2017
  • by Jelle-S
  • Repository
  • 1 Watchers
  • 0 Stars
  • 168 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 0 % Grown

The README.md

BitMaskGenerator

Build Status Code Climate Test Coverage Issue Count, (*1)

Usage:, (*2)

use Jelle_S\Util\BitMask\BitMaskGenerator;
$length = 5;
$minPositives = 2;
// BitMaskGenerator that generates bitmasks with a length of 5 and at least two
// positives (1's).
$generator = new BitMaskGenerator($length, $minPositives);
while ($mask = $generator->getNextMask()) {
  print $mask . "\n";
}

Output:, (*3)

00011
00101
00110
01001
01010
01100
10001
10010
10100
11000
00111
01011
01101
01110
10011
10101
10110
11001
11010
11100
01111
10111
11011
11101
11110
11111

The Versions

11/01 2017

dev-develop

dev-develop

Generates all possible bitmasks with a minimum amount of positives (1's) and a certain length.

  Sources   Download

GPL-3.0+

The Requires

 

The Development Requires

by Jelle Sebreghts

27/12 2016

dev-master

9999999-dev

Generates all possible bitmasks with a minimum amount of positives (1's) and a certain length.

  Sources   Download

GPL-3.0+

The Requires

 

The Development Requires

by Jelle Sebreghts

13/12 2016

1.0.0

1.0.0.0

Generates all possible bitmasks with a minimum amount of positives (1's) and a certain length.

  Sources   Download

GPL-3.0+

The Requires

 

by Jelle Sebreghts