#include #include #include #include #include #include #include int profit(int b, int s, int c) { return abs((b+s)-c); // Return the fixed profit. } int main() { int t; scanf("%i", &t); for(int a0 = 0; a0 < t; a0++){ long long int b; long long int s; long long int c; scanf("%lld %lld %lld", &b, &s, &c); long long int result = profit(b, s, c); printf("%lld\n", result); } return 0; }