/*
Problem C
Time Limit : 2000/1000ms (Java/Other) Memory Limit : 32768/32768K (Java/Other)
Total Submission(s) : 1 Accepted Submission(s) : 1
Problem Description
给定两个整数A和B,其表示形式是:从个位开始,每三位数用逗号","隔开。
现在请计算A+B的结果,并以正常形式输出。
Input
输入包含多组数据数据,每组数据占一行,由两个整数A和B组成(-10^9 < A,B < 10^9)。
Output
请计算A+B的结果,并以正常形式输出,每组数据占一行。
Sample Input
-234,567,890 123,456,7891,234 2,345,678
Sample Output
-111111101
2346912*/
#include<iostream>
#include<string.h>
#include<stdio.h>
#include<ctype.h>
using namespace std;
int main()
{
char s1[20];
char s2[20];
char s3[20];
char s4[20];
while(cin>>s1)
{
int k1=0,k2=0,i;
scanf("%s",s2);
int l1= strlen(s1);
for(i=0;i<l1;i++)
if(s1[i]!=',')
s3[k1++]=s1[i];
s3[k1]='\0';
int l2= strlen(s2);
for(i=0;i<l2;i++)
if(s2[i]!=',')
s4[k2++]=s2[i];
s4[k2]='\0';
int ans = atoi(s3)+atoi(s4);
printf("%d\n",ans);
}
return 0;
}