c++代码
using namespace std;
int k,n,x;
int a[110];
int main(){
while(cin >> n){
for(int i = 0; i < n; i++)cin >> a[i];
cin >> k;
bool f = false;
int c;
for(int i = 0; i < n; i++){
if(a[i] == k){
f = true;
c = i;
break;
}
}
if(f == true){
cout << c << endl;
}else{
cout << "No" << endl;
}
}
return 0;
}