77,625
edits
(I hope this works) |
mNo edit summary |
||
Line 1: | Line 1: | ||
<noinclude> | <noinclude>This template converts decimal values into hex values of up to 6 digits. You are free to edit this page and improve its efficiency, use it on your userpage, or even mainspace it if lots of people use it. | ||
This template converts decimal values into hex values of up to 6 digits. You are free to edit this page and improve its efficiency, use it on your userpage, or even mainspace it if lots of people use it. | |||
</noinclude>{{#iferror: {{#expr: {{{1|0}}} + 1 }} | Value must be numeric | {{#ifexpr:{{{1|0}}} > {{#expr: 16^6 - 1}}|Decimal value must be less than or equal to {{#expr: 16^6 - 1}}|{{#ifexpr:{{{1|0}}} < 0|Decimal value must be greater than 0|{{#switch:{{#expr:floor({{{1|0}}}/16^5)}}|0=0|1=1|2=2|3=3|4=4|5=5|6=6|7=7|8=8|9=9|10=A|11=B|12=C|13=D|14=E|15=F|!}}{{#switch: {{#expr:floor(({{{1|0}}} mod 16^5)/16^4)}}|0=0|1=1|2=2|3=3|4=4|5=5|6=6|7=7|8=8|9=9|10=A|11=B|12=C|13=D|14=E|15=F|!}}{{#switch: {{#expr:floor((({{{1|0}}} mod 16^5) mod 16^4)/16^3)}}|0=0|1=1|2=2|3=3|4=4|5=5|6=6|7=7|8=8|9=9|10=A|11=B|12=C|13=D|14=E|15=F|!}}{{#switch: {{#expr:floor(((({{{1|0}}} mod 16^5) mod 16^4) mod 16^3)/16^2)}}|0=0|1=1|2=2|3=3|4=4|5=5|6=6|7=7|8=8|9=9|10=A|11=B|12=C|13=D|14=E|15=F|!}}{{#switch: {{#expr:floor((((({{{1|0}}} mod 16^5) mod 16^4) mod 16^3) mod 16^2) /16)}}|0=0|1=1|2=2|3=3|4=4|5=5|6=6|7=7|8=8|9=9|10=A|11=B|12=C|13=D|14=E|15=F|!}}{{#switch: {{#expr:((((({{{1|0}}} mod 16^5) mod 16^4) mod 16^3) mod 16^2) mod 16)}}|0=0|1=1|2=2|3=3|4=4|5=5|6=6|7=7|8=8|9=9|10=A|11=B|12=C|13=D|14=E|15=F|!}}}}}}}} | </noinclude>{{#iferror: {{#expr: {{{1|0}}} + 1 }} | Value must be numeric | {{#ifexpr:{{{1|0}}} > {{#expr: 16^6 - 1}}|Decimal value must be less than or equal to {{#expr: 16^6 - 1}}|{{#ifexpr:{{{1|0}}} < 0|Decimal value must be greater than 0|{{#switch:{{#expr:floor({{{1|0}}}/16^5)}}|0=0|1=1|2=2|3=3|4=4|5=5|6=6|7=7|8=8|9=9|10=A|11=B|12=C|13=D|14=E|15=F|!}}{{#switch: {{#expr:floor(({{{1|0}}} mod 16^5)/16^4)}}|0=0|1=1|2=2|3=3|4=4|5=5|6=6|7=7|8=8|9=9|10=A|11=B|12=C|13=D|14=E|15=F|!}}{{#switch: {{#expr:floor((({{{1|0}}} mod 16^5) mod 16^4)/16^3)}}|0=0|1=1|2=2|3=3|4=4|5=5|6=6|7=7|8=8|9=9|10=A|11=B|12=C|13=D|14=E|15=F|!}}{{#switch: {{#expr:floor(((({{{1|0}}} mod 16^5) mod 16^4) mod 16^3)/16^2)}}|0=0|1=1|2=2|3=3|4=4|5=5|6=6|7=7|8=8|9=9|10=A|11=B|12=C|13=D|14=E|15=F|!}}{{#switch: {{#expr:floor((((({{{1|0}}} mod 16^5) mod 16^4) mod 16^3) mod 16^2) /16)}}|0=0|1=1|2=2|3=3|4=4|5=5|6=6|7=7|8=8|9=9|10=A|11=B|12=C|13=D|14=E|15=F|!}}{{#switch: {{#expr:((((({{{1|0}}} mod 16^5) mod 16^4) mod 16^3) mod 16^2) mod 16)}}|0=0|1=1|2=2|3=3|4=4|5=5|6=6|7=7|8=8|9=9|10=A|11=B|12=C|13=D|14=E|15=F|!}}}}}}}} |