#include <bits/stdc++.h>
using namespace std;
int main() {
int t;
cin >> t;
while(t--){
string s;
cin >> s;
int len = s.length();
int m=0;
for(int i=0; i<len; i++){
int t = s[i] -'0';
m = 10*m + t;
}
cout << m << endl;
}
return 0;
}
I2luY2x1ZGUgPGJpdHMvc3RkYysrLmg+CnVzaW5nIG5hbWVzcGFjZSBzdGQ7CgppbnQgbWFpbigpIHsKCWludCB0OwoJY2luID4+IHQ7Cgl3aGlsZSh0LS0pewoJCXN0cmluZyBzOwoJCWNpbiA+PiBzOwoJCWludCBsZW4gPSBzLmxlbmd0aCgpOwoJCWludCBtPTA7CgkJZm9yKGludCBpPTA7IGk8bGVuOyBpKyspewoJCQlpbnQgdCA9IHNbaV0gLScwJzsKCQkJbSA9IDEwKm0gKyB0OwoJCX0KCQljb3V0IDw8IG0gPDwgZW5kbDsKCX0KCXJldHVybiAwOwp9