| 27 | } |
| 28 | } |
| 29 | int main() |
| 30 | { |
| 31 | int n,i,d, arr[10]; |
| 32 | |
| 33 | cout << "\nPlease Enter the Array Size = "; |
| 34 | cin >> n; |
| 35 | cout<<"enter array elements:"<<endl; |
| 36 | d=2; |
| 37 | for(i=0;i<n;i++){ |
| 38 | cin>>arr[i]; |
| 39 | } |
| 40 | rotate(arr,n,d); |
| 41 | print(arr,n); |
| 42 | return 0; |
| 43 | } |