Whole Check
EasyAcc. 98.1%
+20 XP 5
Pure Checks
Not all database amounts natively look like an entire number. When testing items count logic you definitely prefer securely checking decimals out using completely native functions like Number.isInteger().
The Assignment
- Check securely whether
val1runs purely as an integer. - Validate next if
val2securely proves as integer status. - Box up outputs strictly inside array format:
[res1, res2].
01EXAMPLE 1
Input
val1 = 10, val2 = 10.5Output
[true, false]Explanation: 10 is completely clean, 10.5 brings decimal failures.
Constraints
- Apply logically Number.isInteger() effectively.
- Maintain specifically the explicit array returned form.
FundamentalsMathTypes
JavaScriptSystem handles I/O — write your function only
Loading...
5 Hidden
Input Arguments
val110
val210.5
Expected Output
[true,false]
Click RUN to test your solution