https://www.acmicpc.net/problem/10953
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
int main() {
int t;
scanf("%d",&t);
for(int i=0;i<t;i++){
char c[4];
scanf("%s",&c);
char *p=strtok(c,",");
int num=0;
while(p!=NULL){
num+=atoi(p);
p=strtok(NULL,",");
}
printf("%d\n",num);
num=0;
}
}