-
Notifications
You must be signed in to change notification settings - Fork 42
Open
Description
$ ksh -c 'printf "%.30g\n" 1e{10..31}'
10000000000
100000000000
1000000000000
10000000000000
100000000000000
1000000000000000
10000000000000000
100000000000000000
100000000000000000
100000000000000000
100000000000000000
100000000000000000
100000000000000000
100000000000000000
100000000000000000
100000000000000000
100000000000000000
100000000000000000
100000000000000000
100000000000000000
1e+30
1e+31
Same with typeset -E:
$ ksh -c 'typeset -E30 i; for i in 1e{10..31}; do print "$i"; done'
10000000000
100000000000
1000000000000
10000000000000
100000000000000
100000000000000
100000000000000
100000000000000
100000000000000
100000000000000
100000000000000
100000000000000
100000000000000
100000000000000
100000000000000
100000000000000
100000000000000
100000000000000
100000000000000
100000000000000
1e+30
1e+31
With both:
$ ksh --version
version sh (AT&T Research) 93u+m/1.0.10 2024-08-01
on Debian testing amd64 and current git head:
$ ksh --version
version sh (AT&T Research) 93u+m/1.1.0-alpha+de24bb01 2026-03-23
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels