結果

問題 No.185 和風
ユーザー yaoshimaxyaoshimax
提出日時 2015-05-10 11:40:12
言語 Python2
(2.7.18)
結果
AC  
実行時間 15 ms / 1,000 ms
コード長 175 bytes
コンパイル時間 544 ms
コンパイル使用メモリ 6,604 KB
実行使用メモリ 6,212 KB
最終ジャッジ日時 2023-09-19 09:39:58
合計ジャッジ時間 1,295 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 13 ms
5,844 KB
testcase_01 AC 14 ms
6,092 KB
testcase_02 AC 15 ms
6,212 KB
testcase_03 AC 14 ms
6,016 KB
testcase_04 AC 15 ms
5,968 KB
testcase_05 AC 12 ms
5,860 KB
testcase_06 AC 14 ms
6,020 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N=int(raw_input())
XY=[map(int,raw_input().split()) for i in range(N)]
ans=XY[0][1]-XY[0][0]
if ans <=0:
    ans=-1
for x,y in XY:
    if y-x != ans:
        ans=-1
print ans
0