| 26 | return 1; // if everything is ok and the element came successfully out of loop means it is sorted return 1 for thet |
| 27 | } |
| 28 | int main() |
| 29 | { |
| 30 | struct Array arr; |
| 31 | cout << "Enter the size of Array " << endl; |
| 32 | cin >> arr.size; |
| 33 | arr.A = new int[arr.size]; |
| 34 | int no; |
| 35 | cout << "Enter the length of the array " << endl; |
| 36 | cin >> no; |
| 37 | arr.length = 0; |
| 38 | cout << "Enter the elements of the array " << endl; |
| 39 | for (int i = 0; i < no; i++) |
| 40 | cin >> arr.A[i]; |
| 41 | arr.length = no; |
| 42 | cout<<IsSorted(&arr); |
| 43 | return 0; |
| 44 | } |
nothing calls this directly
no test coverage detected