Null character

The null character is a control character at the code position 0 and is part of many character sets such as ASCII, ISO 8859 or Unicode, and it ranks among the so-called " C0 - signs" that are in the range from 0 to 31. As a shortcut is normally used "NUL ".

History

The original meaning of the null character is similar to NOP ( No Operation, English for no function). When it is sent to a printer or a terminal, the device does nothing. On tape this sign is shown as a total absence of holes. An empty tape is so filled with null characters.

Use

The null character can be used on storage media as leaders to fill, for example, unused space. In some transmission protocols, it is used as a time fill signal which can be inserted at will into a message and is discarded by the receiver. This delays on the sender side can be bridged with synchronous data transmission without affecting the actual user data.

In some programming languages ​​, such as C, the null character is used as a marker for the end of a string. Since it can not be entered directly into normal text editors, it is in the source code by the escape sequence "\ 0" ( backslash followed by digit 0 ) or in hexadecimal 0x00.

Unicode

The null character is in the Unicode Basic Latin block (C0 Controls and Basic Latin) at position 0

Representation

The null character is not directly representable as a control character. However, there are different conventions of representation that are substituted for the control characters to be displayed:

  • Control character
611011
de