| 37 | |
| 38 | |
| 39 | int main() |
| 40 | { |
| 41 | std::ios::sync_with_stdio(false); //fastio |
| 42 | int T; |
| 43 | cin>>T; |
| 44 | while(T--) |
| 45 | { |
| 46 | ll n; |
| 47 | cin>>n; |
| 48 | if(n%4 == 2){ |
| 49 | cout<<"NO"<<endl; |
| 50 | continue; |
| 51 | }else{ |
| 52 | cout<<"YES"<<endl; |
| 53 | } |
| 54 | ll s= 0; |
| 55 | for(int i = 0;i<n/2;i++){ |
| 56 | cout<<2*(i +1 )<<" "; |
| 57 | s += 2*(i+1); |
| 58 | } |
| 59 | for(int i = 0;i<(n/2) - 1;i++){ |
| 60 | cout<<2*i + 1<<" "; |
| 61 | s -= 2*i + 1; |
| 62 | } |
| 63 | cout<<s<<endl; |
| 64 | } |
| 65 | return 0; |
| 66 | } |
nothing calls this directly
no outgoing calls
no test coverage detected