結果
| 問題 |
No.571 3人兄弟(その2)
|
| コンテスト | |
| ユーザー |
sotanakajimacl1
|
| 提出日時 | 2017-10-06 23:23:36 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
RE
(最新)
AC
(最初)
|
| 実行時間 | - |
| コード長 | 641 bytes |
| コンパイル時間 | 1,130 ms |
| コンパイル使用メモリ | 158,744 KB |
| 実行使用メモリ | 6,824 KB |
| 最終ジャッジ日時 | 2024-11-17 01:58:23 |
| 合計ジャッジ時間 | 3,516 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | RE * 2 |
| other | RE * 12 |
コンパイルメッセージ
main.cpp: In function ‘int out(int)’:
main.cpp:8:1: warning: no return statement in function returning non-void [-Wreturn-type]
8 | }
| ^
ソースコード
#include<bits/stdc++.h>
using namespace std;
int h[3],w[3],jyuni[3];
int out(int a){
if(a==0) cout<<"A"<<endl;
else if(a==1) cout<<"B"<<endl;
else cout<<"C"<<endl;
}
int main(){
for(int i=0;i<3;i++){
cin>>h[i]>>w[i];
}
for(int i=0;i<3;i++){
jyuni[i]++;
for(int j=0;j<3;j++){
if(i!=j){
if(h[i]<h[j]) jyuni[i]++;
if(h[i]==h[j]){
if(w[i]>w[j]) jyuni[i]++;
}
}
}
}
for(int i=1;i<=3;i++){
for(int j=0;j<3;j++){
if(jyuni[j]==i) out(j);
}
}
return 0;
}
sotanakajimacl1