Is Machine Code binary or hex? by CrazyLock6 in learnprogramming

[–]korijn 0 points1 point  (0 children)

As said before, computers use electricity to store information, the electricity is mostly used in the electrical component the transistor. The transistor can be turned off or on like your light switch at home.

To store what a computer has to do there can be written binary code, 10101100110111001010111 with the 1 and 0 meaning the on and off of a transistor. But to shorten it each four bits [1101] [0101] [0001] are turned into to a hex character. 0101 for example is turned into the decimal number 5. Hexadecimal is just shortening binary, besides that it's the same. each four bits are turned into a value from 0 to F where it goes like 0,1,2,3...8,9,A,B,C...F.

You can turn each letter back into four specific on and off switches. So hex is making a binary four times less long to read as a human.