num = rand(10000) + 1 printf "Cross sum of the number %d becomes ", num sum = 0 while num > 0 sum += num % 10 num /= 10 end printf "%d.\n", sum