結果
| 問題 |
No.185 和風
|
| コンテスト | |
| ユーザー |
Nagisa
|
| 提出日時 | 2015-09-06 08:49:39 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
AC
|
| 実行時間 | 33 ms / 1,000 ms |
| コード長 | 240 bytes |
| コンパイル時間 | 273 ms |
| コンパイル使用メモリ | 12,672 KB |
| 実行使用メモリ | 10,752 KB |
| 最終ジャッジ日時 | 2024-07-19 04:19:33 |
| 合計ジャッジ時間 | 847 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 7 |
ソースコード
N = int(input())
D = [list(map(int, input().split())) for x in range(N)]
L = [D[x][1]-D[x][0] for x in range(N)]
p = L[0]
for n in range(N):
if L[n-1] == L[n]:
pass
else: p = -1
if p > 0:
print(p)
else:
print('-1')
Nagisa