Whole Number

A whole number is an integer that is 0 or greater. The first five whole numbers are 0, 1, 2, 3, and 4. They continue upwards to infinity.

Whole numbers are almost identical to natural numbers except they include 0. This is important in computer science since numeric ranges often begin with zero. For example, the first record in an array is 0, rather than one. 24-bit RGB color provides a range of 0 to 255 for red, green, and blue values. These values are represented by whole numbers rather than natural numbers because they include 0.

As the name implies, a whole number is not a fraction. It also cannot be negative. Since integers range from negative infinity to positive infinity, whole numbers are a subset of integers.

Updated June 19, 2018 by Per C.

quizTest Your Knowledge

What is a reward offered for finding and reporting software vulnerabilities called?

A
Malware payload
0%
B
Smart contract
0%
C
Bug bounty
0%
D
Virus definition
0%
Correct! Incorrect!     View the Bug Bounty definition.
More Quizzes →

The Tech Terms Computer Dictionary

The definition of Whole Number on this page is an original definition written by the TechTerms.com team. If you would like to reference this page or cite this definition, please use the green citation bar directly below the definition.

Our goal to explain computer terminology in a way that is easy to understand. We strive for accuracy and simplicity with every definition we publish. If you have feedback about this definition or would like to suggest a new technical term, please contact us.

TechTerms Newsletter

Improve your technical knowledge with our daily or weekly newsletter! Subscribe today and get new terms and quizzes delivered to your inbox.

Sign up for the free TechTerms Newsletter

How often would you like to receive an email?

You can unsubscribe or change your frequency setting at any time using the links available in each email.

Questions? Please contact us.