Created
December 4, 2017 14:33
-
-
Save hansen033/9d8f2348b2a2d4d10556b3d108ebdcf3 to your computer and use it in GitHub Desktop.
2017/11/23
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| using namespace std; | |
| int main() | |
| { | |
| int num[10], AL; | |
| cout << "請輸入要算的10個平均數(小數點會不見):\n"; | |
| for( int t = 0,plus ; t < 10 ; t ++ ){ | |
| cin >> num[t]; | |
| } | |
| for( int t = 0,plus ; t < 10 ; t ++ ){ | |
| AL += num[t]; | |
| } | |
| cout << "\n這10個數的平均數是:" << AL / 10; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment