

Hexadecimal – or called “hex” by coders for convenience – is a programming convention used to enable raw binary or octal values to be represented in a more readable form. Hex comprises 16 bits – one “word” – or two bytes in octal. In the 70s, the first programmable computers commercially available used toggle switches on the front panel to accomplish routine tasks, such as loading a bootstrap or a driver. The DEC PDP-11 series of computers is one example. It was far easier to use three fingers and load: 012700; 177406; 012710; etc, to boot from an RK-02 disk than use strictly 0s and 1s, with far less likelihood of a mistake.
Hexadecimal is the logical evolution from octal. Those same numbers shown in octal above would be 15C0 for 012700; FF06 for 177406; and 15C8 for 012710. This was far more convenient to enter from a keypad similar to a telephone keypad than either binary or octal. Today, octal is used in code to build masks, but rarely much else. Some remnants of octal still remain, such as the subnet masks for IP addresses, or red, blue, green (RGB) values for colors.
Converting from hexadecimal to string values or string to hexadecimal is simple. Virtually all programming languages have built-in string function manipulation and conversions. Even high-level web programming languages use hex, especially for representing colors or symbol characters.
By its strictest definition, a string is alphanumeric and not interpreted as a numerical representation. To perform arithmetic or logical operations using an alphanumeric requires the programmer to convert a string to hex. For example: If a city has dead people living in it, what is the population? As a string, there are no living people in the city. However, if the string “dead” is converted to hex, then there is a living population of 57005 people. Similarly, if the population is 57005 and the decimal number is first converted to hex, then the convert a string to hex function is used, the city has a dead population.
Hexadecimal values take the form of the numbers 0 to 9 and the letters A through F – a total of 16 characters. When coders “speak” hex, many use phonetics to prevent confusion. As a hexadecimal example, the value “4D2” would be read “four delta two”. Otherwise it might sound too much like “42”.
One of the included tools with Microsoft applications is a scientific calculator. It is usually set to the default of a standard calculator, however it can be easily changed by altering the “View” setting. Using the radio buttons and the keypad, it is a simple matter to convert decimal numbers to octal or hex or vice versa. Example with our hex to decimal converter
Additionally, there are a number of tools readily available online for the coder, from free string function online tools which enable the coder to execute string functions online to a wealth of knowledge contained in a wide variety of string tutorials, string function tutorials, and string to hex tutorials.
Posted in Hexadecimal | No Comments »
If you have a question, noticed a problem, want to share an idea or simply want to comment this page, fill the box below and hit the "Submit" button
String to Lowercase Converter -
String to Uppercase Converter -
String to Hex Converter
Hex to String Converter -
Reverse String Online -
String Length Function -
Html Decode Online
Html Encode Online -
Url Decode Online -
Url Encode Online -
Hex to Binary Converter
Binary to Hex Converter -
Hex to Decimal Converter -
Convert a Decimal to Hex -
Binary to Decimal Converter
Decimal to Binary Converter -
Md5 Hash Online -
Sha1 Hash Online -
Md5 Reverse Lookup
Sha1 Reverse Lookup -
Ascii to Binary Converter -
Ascii to Decimal Converter
Convert Hex to Rgb -
Convert Rgb to Hex
