結果
問題 | No.131 マンハッタン距離 |
ユーザー |
![]() |
提出日時 | 2017-06-27 09:28:39 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
AC
|
実行時間 | 28 ms / 5,000 ms |
コード長 | 261 bytes |
コンパイル時間 | 225 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 10,880 KB |
最終ジャッジ日時 | 2024-10-04 11:22:20 |
合計ジャッジ時間 | 1,643 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 24 |
ソースコード
#131 manhattann distancex,y,d=(int(i) for i in input().split())if x+y<d:print(0)else:if x>y:m=yt=xelse:m=xt=yif d<m:print(d+1)elif d<=t:print(m+1)else:print(x+y-d+1)