1. Home
  2. Computing & Technology
  3. C / C++ / C#

Definition of Precision

By David Bolton, About.com

Definition: The precision of a variable is how many digits it can store accurately. A float can hold only 7 whereas a double can hold 15.

Note this is all the digits in a number not just after a decimal point. So 786.5432987 will not be stored accurately in a float, but will be in a double as it contains 10 digits.

Glossary:

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Examples: In financial calculations, Japanese Yen can be counted in the trilions so need to be stored in doubles.

Explore C / C++ / C#

More from About.com

  1. Home
  2. Computing & Technology
  3. C / C++ / C#
  4. Glossary
  5. P
  6. Precision - Definition

©2008 About.com, a part of The New York Times Company.

All rights reserved.