Submission #00139


ソースコード

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#include <bits/stdc++.h>
using namespace std;
#define endl "\n"
#define inf 1001001001
template<class T> bool chmax(T &a, const T &b) { if(a < b) {a = b; return true;} return false; }
template<class T> bool chmin(T &a, const T &b) { if(b < a) {a = b; return true;} return false; }
//================================================================================================
int main(){
int sum = 0, max = 40;
int test[5] = {};
for(int i = 0; i < 5; i++){
cin >> test[i];
chmax(test[i], max);
sum += test[i];
}
cout << sum / 5 << endl;
return(0);
}

ステータス

項目 データ
問題 0005 - 平均点 (Average Score)
ユーザー名 ei2212
投稿日時 2024-04-26 16:13:01
言語 C++17
状態 Accepted
得点 10
ソースコード長 620 Byte
最大実行時間 28 ms
最大メモリ使用量 668 KB

セット

セット 得点 Cases
1 set1 2 / 2 *1.txt
2 set2 2 / 2 *[12].txt
3 set3 2 / 2 *[1-3].txt
4 set4 2 / 2 *[1-4].txt
5 set5 2 / 2 *[1-5].txt

テストケース

ファイル名 状態 実行時間 メモリ使用量 #
2014-yo-t1-in1.txt AC 22 ms 604 KB
1
2
3
4
5
2014-yo-t1-in2.txt AC 18 ms 572 KB
2
3
4
5
2014-yo-t1-in3.txt AC 28 ms 668 KB
3
4
5
2014-yo-t1-in4.txt AC 23 ms 636 KB
4
5
2014-yo-t1-in5.txt AC 23 ms 608 KB
5