hex: Difference between revisions
Jump to navigation
Jump to search
(New page: ==Function hex== Returns a string which contains the hexadecimal representation of the number that was passed in. ===Usage=== <source lang="mtmacro" line> [h: hexVal = hex(num) </source> ...) |
No edit summary |
||
(5 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
= | {{MacroFunction | ||
|name=hex | |||
|description= | |||
Returns a string which contains the hexadecimal representation of the number that was passed in. | Returns a string which contains the hexadecimal representation of the number that was passed in. | ||
|usage= | |||
< | <syntaxhighlight lang="mtmacro" line> | ||
[h: hexVal = hex(num) | [h: hexVal = hex(num) | ||
</ | </syntaxhighlight> | ||
|examples= | |||
<syntaxhighlight lang="mtmacro" line> | |||
< | |||
[r: hex(23)] | [r: hex(23)] | ||
</ | </syntaxhighlight> | ||
Returns 0x17. | Returns 0x17. | ||
< | <syntaxhighlight lang="mtmacro" line> | ||
[r: hex(10)] | [r: hex(10)] | ||
</ | </syntaxhighlight> | ||
Returns 0xA. | Returns 0xA. | ||
}} | |||
[[Category:Mathematical Function]] |
Latest revision as of 23:59, 15 March 2023
hex() Function
Returns a string which contains the hexadecimal representation of the number that was passed in.
Usage
[h: hexVal = hex(num)
Examples
[r: hex(23)]
Returns 0x17.
[r: hex(10)]