結果
| 問題 |
No.965 門松列が嫌い
|
| コンテスト | |
| ユーザー |
soto800
|
| 提出日時 | 2020-01-13 20:28:37 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 517 bytes |
| コンパイル時間 | 1,441 ms |
| コンパイル使用メモリ | 166,268 KB |
| 実行使用メモリ | 6,824 KB |
| 最終ジャッジ日時 | 2024-12-21 16:15:42 |
| 合計ジャッジ時間 | 1,938 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 1 |
| other | WA * 9 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
#define lli long long int
#define REP(i,s,n) for(int i=s;i<n;i++)
#define MOD 1000000007
#define NUM 2520
#define INF (1LL<<50)
#define DEBUG 0
#define mp(a,b) make_pair(a,b)
#define SORT(V) sort(V.begin(),V.end())
#define PI (3.141592653589794)
signed main(){
lli a,b,c;
cin>>a>>b>>c;
if(c>a)swap(a,b);
if(a==c){
cout<<0<<endl;
return 0;
}
lli ans = INF;
if(a<b){
ans = min(ans,b-a+1);
ans = min(ans,a-c);
}
else{
cout<<0<<endl;
}
return 0;
}
soto800