Hey guys! I was wondering if you could help me out with the thought process behind converting a Hex character into binary. The way it's given as input would be as a char like 0x35. From my perspective the best way to go about it would be to convert each number backwards and stop when the input value is x.

So with an input 0x35 I'd work my way backward and convert 5 to 0101 and 3 to 0011 then conjoin them and print out 00110101. But I'm wondering if this is indeed the best method to use, and exactly how I can get the last digit of a character. I know that you can use modulus 10 to grab the last digit of an int multiple times, but I'm not sure how to go about it with a char.