#include <iostream>
#include <cmath>
using namespace std;
int main(){
int n = 12345; int k, f, r = 0; r = n;
cout << n << endl;
while( n != 0 ){ n /= 10; k++; }
// cout << round(k/2) << endl;
while( r != 0 ){ r /= 10; f++; if(f == round(k/2)) cout << r % 10; }
return 0;
}