Test integerness: Difference between revisions
Content added Content deleted
No edit summary |
|||
Line 357: | Line 357: | ||
=={{header|Lua}}== |
=={{header|Lua}}== |
||
<lang lua> |
<lang lua> |
||
function IsInt(What) |
function IsInt(What) |
||
if tonumber(What) == What and math.floor(tonumber(What)) == tonumber(What) then |
if tonumber(What) == What and math.floor(tonumber(What)) == tonumber(What) then |
||
Line 373: | Line 373: | ||
IsInt(123123123123123):true |
IsInt(123123123123123):true |
||
</pre> |
</pre> |
||
=={{header|ooRexx}}== |
=={{header|ooRexx}}== |
||
<lang oorexx>/* REXX --------------------------------------------------------------- |
<lang oorexx>/* REXX --------------------------------------------------------------- |