Sum
Simple PHP package for add two numbers
Installation
To get the latest version of Sum
, simply require the project using Composer:
composer require nazububu/sum
Or manually update require
block of composer.json
and run composer update
.
{
"require": {
"nazububu/sum": "^1.0"
}
}
Using
use Nazububu\Sum\Sum;
$sum = new Sum;
echo $sum->calculate(1, 1); // 2
Testing
You can run tests with command
vendor/bin/phpunit tests/