Take a list of 2-digit hexadecimal numbers as input, and output the binary value, replacing each 1 with an 'X', and each 0 with a space.
For example
Input = FF, 81, 47, 99
.
FF
=11111111
in binary, so printXXXXXXXX
81
=10000001
in binary, so printX X
47
=01000111
in binary, so printX XXX
99
=10011001
in binary, so printX XX X
Full output:
XXXXXXXX
X X
X XXX
X XX X
Clarifications
- The hexadecimal numbers will always be 2-digits.
- There can be any number of hexadecimal numbers.
- You can choose to input in whatever format you want (separated by a space, comma, newline, etc.)
- The character to output for a
1
isX
, and for0
it is a - The outputs must be padded to length 8
Also, apparently I wasn't clear enough: the input is in Hexadecimal (Base 16) not denary (Base 10)
This is code-golf, so the shortest answer in bytes wins!
0
s to the length of the longest or always to length 8? \$\endgroup\$