Null Character Definition & Meaning

A null character is one that carries no value and has all its bits set to 0. It is available in most major programming languages and many major character sets, including ASCII and Unicode. It is sometimes abbreviated as NUL or referred to as a null byte.

How are null characters used?

Null characters have several use cases. In early computer technology, blank rolls of punched paper tape were considered to consist entirely of null characters that would eventually be replaced once new characters were punched. In database, spreadsheet, and word processor applications, null characters are often displayed as spaces to create padding.

In the C programming language and its derivatives, a null character is represented by . This escape sequence marks the end of a character string. In C++, some examples might look like this:

This sentence will stop after “the” as noted by the null character placement:

cout << “I will not finish the sentence.”;

This sentence stops at its natural end because the null character falls after the period:

cout << “I will finish the sentence.”;

Vangie Beal
Vangie Beal
Vangie Beal is a freelance business and technology writer covering Internet technologies and online business since the late '90s.

Top Articles

The Complete List of 1500+ Common Text Abbreviations & Acronyms

Text Abbreviations reviewed by Web Webster   From A3 to ZZZ we list 1,559 SMS, online chat, and text abbreviations to help you translate and understand...

How to Create a Website Shortcut on Your Desktop

Website Shortcut on Your Desktop reviewed by Web Webster   This Webopedia guide will show you how to create a website shortcut on your desktop using...

Windows Operating System History & Versions

The Windows operating system (Windows OS) refers to a family of operating systems developed by Microsoft Corporation. We look at the history of Windows...

First to Fifth Generations of Computers

Reviewed by Web Webster   Learn about each of the 5 generations of computers and major technology developments that have led to the computing devices that...

Heuristic Definition and Meaning

Heuristic, pronounced hyoo-ri-stihk, is a Greek term for individually finding or discovering. In...

Hackerspace Definition & Meaning

What is a hackerspace? A hackerspace, also known as a hacklab, incubator, or hackspace,...

Random Access Memory (RAM)...

Random Access Memory (RAM) reviewed by Web Webster   Random Access Memory (RAM) is a...