Lang:G++
Edit12345678910111213141516171819202122232425262728293031/*ID: y1197771PROG: testLANG: C++*/#include<bits/stdc++.h>#define pb push_back#define FOR(i, n) for (int i = 0; i < (int)n; ++i)#define dbg(x) cout << #x << " at line " << __LINE__ << " is: " << x << endltypedef long long ll;using namespace std;typedef pair<int, int> pii;const int maxn = 1e3 + 10;string add(string s1, string s2) {int n = s1.size(), m = s2.size();int i, j, c; c = i = j = 0;string res = "";while(i < n && j < m) {int d = s1[i] + s2[j] - '0' * 2 + c;c = d / 10;d = d % 10;res += char('0' + d);i++; j++;}while(i < n) {int d = s1[i] - '0' + c;c = d / 10; d = d % 10;res += char('0' + d);i++;}while(j < m) {