Literals/Integer: Difference between revisions

Content added Content deleted
m (→‎{{header|Kotlin}}: added note about underscores)
Line 1,201: Line 1,201:


Signed and unsigned integer literals can be forced to be interpreted as Long or ULong respectively by appending the suffix <code>L</code> to the literal (lower case 'l' is not allowed as it is easily confused with the digit '1').
Signed and unsigned integer literals can be forced to be interpreted as Long or ULong respectively by appending the suffix <code>L</code> to the literal (lower case 'l' is not allowed as it is easily confused with the digit '1').

Underscores can be used between digits of a literal for clarity.


<syntaxhighlight lang="kotlin">
<syntaxhighlight lang="kotlin">