結果

問題 No.131 マンハッタン距離
ユーザー fiord
提出日時 2015-04-26 15:34:17
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
WA  
実行時間 -
コード長 185 bytes
コンパイル時間 386 ms
コンパイル使用メモリ 54,640 KB
実行使用メモリ 6,948 KB
最終ジャッジ日時 2024-07-05 02:48:38
合計ジャッジ時間 2,772 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2 WA * 1
other AC * 17 WA * 7
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
using namespace std;
int main(){
	int x,y,d;	cin>>x>>y>>d;
	int cnt=0;
	for(int i=d-y;i<=x;i++){
		if(0<=d-i)	cnt++;
		else break;
	}
	cout<<cnt<<endl;
	return 0;
}
0