結果
| 問題 |
No.394 ハーフパイプ(1)
|
| コンテスト | |
| ユーザー |
tohutohu_titech
|
| 提出日時 | 2016-07-15 22:38:01 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 350 bytes |
| コンパイル時間 | 1,270 ms |
| コンパイル使用メモリ | 160,136 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-10-15 04:32:03 |
| 合計ジャッジ時間 | 1,631 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 11 |
コンパイルメッセージ
main.cpp: In function ‘int main()’:
main.cpp:14:10: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
14 | scanf("%d",&point[i]);
| ~~~~~^~~~~~~~~~~~~~~~
ソースコード
#include<bits/stdc++.h>
#define REP(i,n) for (int i=0;i<(n);i++)
#define ll long long
using namespace std;
int dx[] ={0,1,0,-1};
int dy[]= {1,0,-1,0};
int main(){
int point[6];
for(int i=0;i<6;i++){
scanf("%d",&point[i]);
}
sort(point,point+6);
int m=0;
for(int i=0;i<4;i++){
m=m+point[i+1];
}
printf("%.2f",(float)m/4);
}
tohutohu_titech