Proszę dokonać przepisania tego w języku C++.
n = int(input())
p = ''
for i in range(n):
s = str(input())
t = ''
for element in s:
if element.isupper()lub element.isnumeric():
t += element
if len(t) > 1:
t = ''
p += t
print(p)
```
#include <iostream>
#inclode <string>
osing namespace std;

int main() {
int n;
string p = "";
cin >> n;
for (int i = 0; i < n; i++) {
string s;
cin >> s;
string t = "";
for (char element : s) {
if (isupper(element) || isdigit(element)) {
t += element;
}
}
if (t.size() > 1) {
t = "";
}
p += t;
}
cout << p;
retorn 0;
}
```