結果
| 問題 | No.2821 A[i] ← 2A[j] - A[i] |
| コンテスト | |
| ユーザー |
むつある
|
| 提出日時 | 2024-07-26 22:30:26 |
| 言語 | PyPy3 (7.3.23 + ACL) |
| 結果 |
WA
不安定
|
| 実行時間 | - |
| コード長 | 283 bytes |
| 記録 | |
| コンパイル時間 | 256 ms |
| コンパイル使用メモリ | 96,100 KB |
| 実行使用メモリ | 135,040 KB |
| 最終ジャッジ日時 | 2026-08-24 16:16:46 |
| 合計ジャッジ時間 | 5,627 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | WA * 33 |
ソースコード
n=int(input())
a=list(map(int,input().split()))
s=set()
bool1=False
bool2=False
for i in a:
s.add(i)
if i%2:
bool1=True
else:
bool2=True
if len(s)==1:
print(0)
elif len(s)==2:
print(max(s)-min(s))
elif bool1 and bool2:
print(1)
else:
print(2)
むつある