[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
GNU Emacs supports two numeric data types: integers and floating point numbers. Integers are whole numbers such as -3, 0, 7, 13, and 511. Their values are exact. Floating point numbers are numbers with fractional parts, such as -4.5, 0.0, or 2.71828. They can also be expressed in exponential notation: 1.5e2 equals 150; in this example, `e2' stands for ten to the second power, and that is multiplied by 1.5. Floating point values are not exact; they have a fixed, limited amount of precision.
3.1 Integer Basics Representation and range of integers. 3.2 Floating Point Basics Representation and range of floating point. 3.3 Type Predicates for Numbers Testing for numbers. 3.4 Comparison of Numbers Equality and inequality predicates. 3.5 Numeric Conversions Converting float to integer and vice versa. 3.6 Arithmetic Operations How to add, subtract, multiply and divide. 3.7 Rounding Operations Explicitly rounding floating point numbers. 3.8 Bitwise Operations on Integers Logical and, or, not, shifting. 3.9 Standard Mathematical Functions Trig, exponential and logarithmic functions. 3.10 Random Numbers Obtaining random integers, predictable or not.