#include #define FastIO (cin.tie(0), cout.tie(0), ios::sync_with_stdio(false)) #define rep(i, n) for (int i = 0; i < (int)(n); i++) using namespace std; void solve() { int n; cin >> n; rep(i, n) { string hitsuji, ga, hiki; int sheep; cin >> hitsuji >> ga >> sheep >> hiki; cout << hitsuji << " " << ga << " " << sheep + 1 << " " << hiki << '\n'; } } int main() { FastIO; solve(); return 0; }