Nov-02-2019, 06:26 AM
you can use python built-in command.
sum(map(int, str(x)))Point to study. builtin function map, str, and study about Python iterable.