PHP Check if number is odd


/ Published in: PHP
Save to your folder(s)



Copy this code and paste it in your HTML
  1. function checkNum($num){
  2. return ($num%2) ? TRUE : FALSE;
  3. }

URL: http://www.phpro.org/examples/Check-if-number-is-Odd-or-Even.html

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.