I worked with PHP code, which would be the expected result:
1
101
10001
1000001
100000001
10000000001
1000000000001
100000000000001
10000000000000001
1000000000000000001
finally, the output was:
1
101
10001
1000001
100000001
10000000001
1000000000001 // (1 billion) to (100 billion - 1), showing the actual number, and then
1.0E + 14
1.0E + 16
1.0E + 18
I found some solutions there! they said using sprintf or by trying format_number . I tried both.
using sprintf and the result:
$format_x = sprintf("%.0f ",$x); echo $format_x.$br;
1
101
10001
1000001
100000001
10000000001
1000000000001
100000000000001
10000000000000000
1000000000000000000
using format_number and the result:
echo number_format($x, 0).$br;
1
101
10001
1000001
100000001
10000000001
1.000.000.000.001
100.000.000.000.001
10.000.000.000.000.000
1,000,000,000,000,000,000
but it still does not show actual large numbers. ok, the two ways looked good, but that doesn't match what I want. can anyone resolve this?
source share