Result

AC

Code [DL]

while read -n1 c;do a[c]+=$c;done
IFS=;echo "${a[*]}"

stdin

0548739672163929002178363475702499337610171601743544926228906866712111580010461012744968548580372084

stdout

0000000000000111111111111122222222223333333344444444444555555666666666667777777777788888888899999999

stderr

/bin/bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)

strace