Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <math.h>
- using namespace std;
- int main()
- {
- int a[10];
- double sr, sum=0;
- for (int i = 0; i < 10; i++)
- {
- cout << "a[" << i << "]=";
- cin >> a[i];
- }
- for (int i = 0; i < 10; i++)
- {
- sum = sum + a[i];
- }
- sr = sum / 10;
- cout << sr;
- //for (int i = 0; i < 10; i++)
- //{
- // cout << a[i];
- // cout << endl;
- //}
- system("pause");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement