#include <iostream>
using namespace std;
void cautare_secventiala(int v[100], int nr_comp_vect, int x) {
for (int contor=1; contor<=nr_comp_vect; contor++) {
if (v[contor]==x) {
cout<<"Apartine!"<<endl;
return;
}
}
cout<<"Nu apartine!"<<endl;
}
int main() {
int v[100], x, nr_comp_vect;
cin>>nr_comp_vect;
for (int contor=1; contor<=nr_comp_vect; contor++) {
cin>>v[contor];
}
cin>>x;
cautare_secventiala(v, nr_comp_vect, x);
return 0;
}