Created
January 29, 2015 08:39
-
-
Save czarpino/6c1837d9972b1cec4a42 to your computer and use it in GitHub Desktop.
Number class for git demonstration
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Number helper class. | |
*/ | |
class NumberHelper | |
{ | |
/** | |
* Check whether the specified number is odd. | |
* | |
* @return bool TRUE when the number is odd, FALSE otherwise | |
*/ | |
public function isOdd($number) | |
{ | |
if (0 === $this->number % 2) { | |
return false; | |
} | |
return true; | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment