You are viewing a single comment's thread. Return to all comments →
why my code gives wrong answers ...?
vector <int> circularArrayRotation(vector <int> a, vector <int> m,int n,int k, int q) { while(k!=0) { int end=a[n-1]; for(int i=n-2;i>=0;i--) { a[i+1]=a[i]; } a[0]=end; k--; } return a; }
Circular Array Rotation
You are viewing a single comment's thread. Return to all comments →
why my code gives wrong answers ...?