#include<stdio.h> int main() { int a=0,b=0,right_count=0,status,sum=0; char c[4]={'+','-','=','?'}; char arithmetic; char arithmetic_1; while((status=scanf("%d%c%d%c%d",&a,&arithmetic,&b,&arithmetic_1,&sum))!=EOF){ switch(arithmetic){ case '+': if(a + b==sum) right_count++; getchar(); break; case '-': if(a - b==sum) right_count++; getchar(); break; } } printf("%d",right_count); return 0; }
0.0分
0 人评分