結果

問題 No.185 和風
ユーザー togatoga
提出日時 2015-08-16 11:50:14
言語 Python2
(2.7.18)
結果
WA  
実行時間 -
コード長 162 bytes
コンパイル時間 48 ms
コンパイル使用メモリ 7,040 KB
実行使用メモリ 6,944 KB
最終ジャッジ日時 2024-07-18 09:49:07
合計ジャッジ時間 522 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 6 WA * 1
権限があれば一括ダウンロードができます

ソースコード

diff #

n = input()
s = set()
for i in range(n):
    a,b = map(int, raw_input().split())
    s.add(b - a)
if (len(s) == 1):
    print max(s.pop(), -1)
else:
    print -1
0