Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- const int SIZE = 10;
- void main()
- {
- {
- cout << "Hello, please enter " << SIZE << " numbers : ";
- int arr[SIZE] = { 0 }, i = 0;
- for (i = 0; i < SIZE; i++)
- cin >> arr[i];
- for (int j = 0; j < SIZE; j++)
- {
- if (j % 2 == 0)
- {
- arr[j] += 1;
- cin >> arr[j];
- }
- }
- for (int j = 0; j < SIZE; j++)
- {
- cout << arr[j];
- }
- system("pause");
- system("CLS");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment