# Check if number is whole number

**URL:** <https://forum.kirupa.com/t/check-if-number-is-whole-number/114173>\
**Category:** Uncategorized\
**Created:** [June 25, 2004, 2:15pm UTC](https://forum.kirupa.com/t/check-if-number-is-whole-number/114173 "2004-06-25T14:15:44Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![xEnOn](https://avatars.discourse-cdn.com/v4/letter/x/85e7bf/32.png) [@xEnOn](https://forum.kirupa.com/u/xEnOn)\
**Post date:** [June 25, 2004, 2:15pm UTC](https://forum.kirupa.com/t/check-if-number-is-whole-number/114173/1 "2004-06-25T14:15:44Z")

</div>

i would like to know how can i know if the result of a variable is a whole number or not.  
like…  
var i++;  
if(i =wholenumber) {  
…  
}

i need something like this. the number must be a whole number with no decimals or fractions  
thanks
