Liste des Groupes | Revenir à cl c |
On 07/04/2025 21:14, Janis Papanagnou wrote:In Norwegian, we use the long scale - "million, milliard, billion, billiard, trillion, trilliard". The spelling is the same as in English (I don't know about after "trilliard"), but the pronunciation is a little different.On 07.04.2025 20:18, bart wrote:On 07/04/2025 19:12, Michael S wrote:>On Mon, 7 Apr 2025 19:02:34 +0100>
bart <bc@freeuk.com> wrote:
>On 04/04/2025 04:01, Lawrence D'Oliveiro wrote:On Wed, 2 Apr 2025 16:33:46 +0100, bart wrote:>Here, tell me at a glance the magnitude of>
this number:
>
10000000000
#define THOUSAND 1000
#define MILLION (THOUSAND * THOUSAND)
#define BILLION (THOUSAND * MILLION)
>
uint64 num = 10 * BILLION;
>
Much easier to figure out, don’t you think?
Try 20 * BILLION; it will overflow if not careful.
(Actually both 10/20 billion will overflow u32; I was thinking of 20
billion billion overflowing u64.)
>>I'd normally write '20 billion' outside of C, since I use such>
numbers, with lots of zeros, constantly when writing test code.
>
But when it isn't all zeros, or the base isn't 10, then numeric
separators are better.
>
Is not it "20 milliards" in British English?
We (UK) now use 'billion' for 1E9; in the past it meant 1E12.
>
'Milliardo' is Italian for 'billion'; perhaps in a few other languages too.
"In a few other languages"? - That was not my impression;
and a quick look into Wikipedia seems to support that.
>
The global map[*] is interesting!
>
(Read the articles for the details, the historic base, and
especially what's standard in countries, and why the common
standard is in some cases like GB not used primarily today.)
>https://upload.wikimedia.org/wikipedia/commons/7/7c/World_map_of_long_and_short_scales.svgI'd never heard of short and long scales. The full article is here:
https://en.wikipedia.org/wiki/Long_and_short_scales
I only knew about the old and new meanings of 'billion' in the UK, its US meaning, and the use of 'milliard' (however it is spelt, since I'm only familiar with it in speech), in Italian.
(In source code, it would also be useful to use 1e9 or 1e12, unfortunately those normally yield floating point values. I can't do much about that in C, but I will see what can be done with my own stuff.)
Les messages affichés proviennent d'usenet.