Is () an integer

From PenguinMod Wiki (Official)
Revision as of 04:03, 17 December 2023 by wikia:penguinmod>MediansSC
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

The is an integer block is a boolean block and an operators block that detects if a number is an integer (is not a fraction or a decimal). To get this block, one must add the "Operators Expansion" extension.

Workaround

Taking (whatever) mod (1) reports 0 if the first input is a string or is an integer.

Rounding the number and seeing if it's the same as the original number also works.