Convert binary to hexadecimal using base conversion
Binary (base-2) to hexadecimal (base-16) conversion groups binary digits in sets of 4 (because 2⁴ = 16). Each 4-bit group corresponds to one hex digit: 0000=0, 0001=1, ... 1111=F. For example, 1101 1010 1011 binary = D A B hex.