#include<bits/stdc++.h> using namespace std; int n; int main() { while(cin>>n) { if(n==42) { break; } cout<<n<<endl; } return 0; }