是我题意理解错误了?感觉不用STL也能过,直接零蛋了
#include<bits/stdc++.h>
using namespace std;
const int N = 1e5 + 100;
int q;
int p[N],po[N];
int n;
int main(){
cin >> q;
bool t;
while(q--){
cin >> n;
for(int i = 1 ; i <= n ; i++)cin >> p[i];
for(int i = 1 ; i <= n ; i++){
cin >> po[i];
if(po[i] != p[n + 1 - i])t = 1,break;
}
if(t)cout << "No" << endl;
else cout << "Yes" << endl;
}
return 0;
}