2017 © Pedro Peláez
 

library numeral-system-converter

Convert numbers to different numeral systems.

image

bocharsky-bw/numeral-system-converter

Convert numbers to different numeral systems.

  • Sunday, January 26, 2014
  • by bocharsky-bw
  • Repository
  • 1 Watchers
  • 0 Stars
  • 2 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

numeral-system-converter

Convert numbers to different numeral systems., (*1)

Installation

1) Use require_once for include converter to your code. Add next code before using converter, (*2)

require_once /path-to-numeral-system-converter/src/Converter.php';
use BW\NumeralSystem\Converter;

2) Or use composer to install. Add next code to composer.json file, (*3)

require: "bocharsky-bw/numeral-system-converter": "dev-master", (*4)

Using

echo '

';

print Converter::fromDec(9, Converter::MIN_RADIX) ."\n";
print Converter::toDec('1001', Converter::MIN_RADIX) ."\n";
print "\n";

print Converter::fromDec(11, 16) ."\n";
print Converter::toDec('B', 16) ."\n";
print "\n";

print Converter::fromDec(94276256, Converter::MAX_RADIX) ."\n";
print Converter::toDec('2!w54', Converter::MAX_RADIX) ."\n";
print "\n";

echo '
';

The Versions

26/01 2014

dev-master

9999999-dev https://github.com/bocharsky-bw/numeral-system-converter

Convert numbers to different numeral systems.

  Sources   Download

MIT

The Requires

  • php >=5.3.0
  • ext-curl *
  • ext-json *

 

converter binary octal decimal radix hexadecimal numeral system

26/01 2014

v1.0.0

1.0.0.0 https://github.com/bocharsky-bw/numeral-system-converter

Convert numbers to different numeral systems.

  Sources   Download

MIT

The Requires

  • php >=5.3.0
  • ext-curl *
  • ext-json *

 

converter binary octal decimal radix hexadecimal numeral system