Difference between revisions of "Template:Dec2hex/doc"

From blackwiki
Jump to navigation Jump to search
imported>Zyxw
m (Since <tt> is obsolete in HTML5, replace it with <kbd> – see HTML element#tt, Wikipedia:HTML5, and mw:Help:Extension:Linter/obsolete-tag. using AWB)
imported>Cedar101
(→‎See also: * {{tlx|Hexadecimal}})
 
Line 18: Line 18:
  
 
=== See also ===
 
=== See also ===
{{Math templates|numeral systems}}<includeonly>
+
* {{tlx|Hexadecimal}}
 +
{{Math templates|numeral systems}}
 +
 
 +
<includeonly>
 
<!-- CATEGORIES AND INTERWIKIS HERE, THANKS -->
 
<!-- CATEGORIES AND INTERWIKIS HERE, THANKS -->
  
 
</includeonly>
 
</includeonly>

Latest revision as of 02:41, 31 July 2020

Usage

Works for all values in the range 0–4294967295.

  • {{dec2hex|0}} → 0x0
  • {{dec2hex|160}} → 0xA0
  • {{dec2hex|1984}} → 0x7C0
  • {{dec2hex|65535}} → 0xFFFF
  • {{dec2hex|8675309}} → 0x845FED
  • {{dec2hex|123456789}} → 0x75BCD15
  • {{dec2hex|3735928559}} → 0xDEADBEEF
  • {{dec2hex|4294967295}} → 0xFFFFFFFF
digits
Specify how many digits are show [2,8]. Example: {{dec2hex|65535|digits=8}} → 0xFFFF

See also