#include <iostream>
#include <vector>
using namespace std;
int main(){
ios_base::sync_with_stdio(0);
cin.tie(0);
cout.tie(0);
int n;
cin>>n;
char akt_znak;
vector<char> znak;
while(cin>>akt_znak)
znak.push_back(akt_znak);
cout<<znak[znak.size() - n];
}
I2luY2x1ZGUgPGlvc3RyZWFtPgojaW5jbHVkZSA8dmVjdG9yPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwoKaW50IG1haW4oKXsKICAgIAogICAgaW9zX2Jhc2U6OnN5bmNfd2l0aF9zdGRpbygwKTsKICAgIGNpbi50aWUoMCk7CiAgICBjb3V0LnRpZSgwKTsKIAogICAgaW50IG47CiAgICBjaW4+Pm47CiAgICBjaGFyIGFrdF96bmFrOwogICAgdmVjdG9yPGNoYXI+IHpuYWs7CiAgICB3aGlsZShjaW4+PmFrdF96bmFrKQogICAgem5hay5wdXNoX2JhY2soYWt0X3puYWspOwogICAgCiAgICBjb3V0PDx6bmFrW3puYWsuc2l6ZSgpIC0gbl07CiAgICAKfQ==