Search This Blog

2023/07/26

How to check number is integer

 var num1 = 123


if(num1 % 1 ==0){
console.log("It's Integer")
}

Output:
It's Integer

No comments:

Post a Comment