분류 전체보기71 백준 4344 평균은 넘겠지 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 #include int main() { int loop = 0; int loopMax = 0; scanf("%d", &loopMax); while (loopMax>loop) { int studentNum = 0; scanf("%d", &studentNum); float* scoreList = new float[studentNum]; float inputScore = 0.0f; float sum = 0.0f; float average = 0.0f; int count = 0; float result = 0.0f; fo.. 2019. 9. 3. 백준 8958 OX퀴즈 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 #include #include int main() { int size = 0;; scanf("%d", &size); for (int i = 0; i cs 2019. 9. 3. 백준 평균 1546 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 #include int GetMaxScore(int maxScore , float list[] , int size) { maxScore = 0; for (int idx = 0; idx maxScore) { maxScore = list[idx]; } } return maxScore; } float GetAverage(float average, int score, float list[], int size) { for (int idx = 0.. 2019. 9. 3. 백준 1546 평균 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 #include int GetMaxScore(int maxScore , float list[] , int size) { maxScore = 0; for (int idx = 0; idx maxScore) { maxScore = list[idx]; } } return maxScore; } float GetAverage(float average, int score, float list[], int size) { for (int idx = 0.. 2019. 9. 2. 이전 1 ··· 7 8 9 10 11 12 13 ··· 18 다음