ALCATRAZ1  SUM OF DIGITS
You are being given a number N . (1<=N<=10^50) . You have to print the sum of digits of that particular number .
Input
The first line will contain T , the number of testcases ( T<10) . The next T lines will contain the numbers whose sum of digits you have to calculate .
Output
Output T lines containing the Sum of Digits of the numbers .
Example
Input: 3
123123123
3434
1234567890
Output: 18
14
45
hide comments
karankeswani99:
20190116 16:53:16
AC in one go :)


dwzy:
20181218 02:45:38
java TLE :( 

amantu_amir:
20181030 19:25:43
In cpp take input as string and then convert into int(s[i]  48) and sum them


k10online:
20181016 10:56:47
you can store the number as string and then convert one char to digit and sum it 

aunkhtoo:
20181015 10:42:58
can't solve in java


albiosz:
20180920 12:37:19
In python it is easy, but how to store such a huge number as 123123123 in a string using Cpp? Cpp automatically converts it to the 1.23123123e08 and save this number in such format to a string :/ 

aquib_ansari:
20180709 04:47:31
how to store such a huge number in cpp 

anushka_ahuja:
20180707 15:07:43
very easy !!!


cryo:
20180602 13:31:26
easy one.take care about the input format


ankur314:
20180518 05:20:58
convert every character of string to int and add

Added by:  Alcatraz 
Date:  20161104 
Time limit:  0.019s 
Source limit:  50000B 
Memory limit:  1536MB 
Cluster:  Cube (Intel G860) 
Languages:  All except: ASM64 GOSU 