Talk:Ways of writing numbers: Difference between revisions
From Why start at x, y, z
mNo edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
In the Twitter thread: "Have you seen fractional numbers in hex or octal notation?" | In the Twitter thread: "Have you seen fractional numbers in hex or octal notation?" | ||
Literals like 0x1.123abcp-5 are now standard in C and C++. The exponent (following 'p') is written in decimal. The Handbook of Floating Point Arithmetic (Muller and about a thousand others) uses this format (sometimes without the 0x) to provide exact floating point constants. -- Unsigned comment by [[ | Literals like 0x1.123abcp-5 are now standard in C and C++. The exponent (following 'p') is written in decimal. The Handbook of Floating Point Arithmetic (Muller and about a thousand others) uses this format (sometimes without the 0x) to provide exact floating point constants. -- Unsigned comment by [[User:John McKenna]], 7 July 2021 20:24 |
Latest revision as of 12:01, 8 July 2021
In the Twitter thread: "Have you seen fractional numbers in hex or octal notation?" Literals like 0x1.123abcp-5 are now standard in C and C++. The exponent (following 'p') is written in decimal. The Handbook of Floating Point Arithmetic (Muller and about a thousand others) uses this format (sometimes without the 0x) to provide exact floating point constants. -- Unsigned comment by User:John McKenna, 7 July 2021 20:24