Solution to the problem number ACT of Spoj - ACT.

Any questions do not hesitate to contact.

#include<bits/stdc++.h>
using namespace std;
int main()
{
int t,n;
string s;
cin>>t;
while(t--)
{
 
cin>>n>>s;
n=s.length()-1;
cout<<s[n]<<endl;
}
return 0;
} 

Don't miss anything.

Keep in touch with Isaac Lozano Osorio!