Changes

Jump to navigation Jump to search
780 bytes added ,  22:28, March 24, 2021
Added description of BCD.
Line 8: Line 8:     
In a like manner, floating point values come in various sizes, depending upon the [[floating-point]] standard that is used.  Typically ''single precision'' represents a 32-bit floating-point value, and ''double'' precision represents a 64-bit value.
 
In a like manner, floating point values come in various sizes, depending upon the [[floating-point]] standard that is used.  Typically ''single precision'' represents a 32-bit floating-point value, and ''double'' precision represents a 64-bit value.
 +
 +
Binary-Coded Decimal (BCD) is also used to represent numbers, for instance in [[COBOL]].  BCD encodes a digit using 4 bits, thus allowing 2 digits per byte.  Plus and minus signs, and decimal points are also represented by one of the 16 possible 4-bit values.  Certain bit combinations are invalid as BCD.  Because of the encoding method, BCD is less space-efficient than typical integer or floating point values.  For instance, a 32-bit integer can represent a value from negative 2 billion to positive 2 billion, whereas a 32-bit BCD has a maximum value of 99,999,999 or -9,999,999. Arithmetic operations with it are also slower than other encodings.  However, it can more accurately represent fractional values, and conversion to human-readable numbers is less CPU-intensive.
    
==Strings==
 
==Strings==
SkipCaptcha
292

edits

Navigation menu