You are viewing a single comment's thread. Return to all comments →
In first for loop if you replace cin >> arr[i] with following: int x; cin >> x; arr[i] = x;
That will work otherwise it will fail if you leave your code as it is and try following values it will fail:
8 6676 3216 4063 8373 423 586 8850 6762
Seems like cookies are disabled on this browser, please enable them to open this website
Arrays Introduction
You are viewing a single comment's thread. Return to all comments →
In first for loop if you replace cin >> arr[i] with following: int x; cin >> x; arr[i] = x;
That will work otherwise it will fail if you leave your code as it is and try following values it will fail:
8 6676 3216 4063 8373 423 586 8850 6762