#include <iostream>
#include <sstream>
#include <vector>
#include <string>
using namespace std;
int main(){
int n;
cin >> n;
while(n != 0){
for(int i = 0; i < n; i++){
vector<int> v;
int k;
string s;
while(getline(cin, s)){
stringstream ss(s);
while(ss >> k){
v.push_back(k);
}
}
}
}
cout << "end" << endl;
return 0;
}