結果

問題 No.131 マンハッタン距離
ユーザー J31831276
提出日時 2018-12-28 03:50:50
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
WA  
実行時間 -
コード長 225 bytes
コンパイル時間 380 ms
コンパイル使用メモリ 56,532 KB
実行使用メモリ 5,248 KB
最終ジャッジ日時 2024-10-01 14:57:48
合計ジャッジ時間 1,139 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 20 WA * 4
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <algorithm>
#include <cstdio>
#include <string>

#define ll long long

using namespace std;

int main(){

   int x,y,d;
   cin>>x>>y>>d;
   cout<<min(max(0,x+y-d+1),d+1)<<endl;
   

   return 0;
}
0