题目
#include<iostream>
#include<list>
using namespace std;
char arr[1005] = { '0' };
int main() {
int n;
cin >> n;
list<char>L;
for (int i = 0; i < n; i++) {
cin >> arr[i];
L.push_back(arr[i]);
}
int m;
cin >> m;
for (int i = 0; i < m; i++) {
cin >> arr[i];
L.push_back(arr[i]);
}
list<char>::iterator iter;
iter = L.begin();
for (iter = L.begin(); iter != L.end();iter++) {
cout << *iter << " ";
}
return 0;
}