num = 123
printf "Cross sum of the number %d becomes ", num
sum = 0

while num > 0
  sum += num % 10
  num /= 10
end

printf "%d.\n", sum