結果

問題 No.185 和風
ユーザー mlihua09mlihua09
提出日時 2020-08-27 16:40:54
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 228 bytes
コンパイル時間 350 ms
コンパイル使用メモリ 82,432 KB
実行使用メモリ 61,696 KB
最終ジャッジ日時 2024-04-25 09:59:19
合計ジャッジ時間 1,221 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 46 ms
53,376 KB
testcase_01 AC 61 ms
61,440 KB
testcase_02 AC 40 ms
51,712 KB
testcase_03 AC 40 ms
51,968 KB
testcase_04 WA -
testcase_05 WA -
testcase_06 AC 57 ms
61,312 KB
権限があれば一括ダウンロードができます

ソースコード

diff #


N = int(input())

x, y = map(int, input().split())

ans = y - x

for i in range(N - 1):
    
    x, y = map(int, input().split())
    
    if y - x != ans:
        
        print(-1)
        
        exit()
        
print(ans)
0