Submission #19138

#TimeUsernameProblemLanguageResultExecution timeMemory
19138eaststarMathWorlds (YDX13_mathworlds)C++14
1 / 1
0 ms1084 KiB
#include <stdio.h> char *a=" +-*/"; int main(){ long long x,y,z,s,t=0; scanf("%lld%lld%lld",&x,&y,&z); if(x+y==z)s=1,++t; if(x-y==z)s=2,++t; if(x*y==z)s=3,++t; if(y&&x%y==0&&x/y==z)s=4,++t; if(t!=1)puts("Invalid"); else putchar(a[s]); return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...