結果
| 問題 | No.816 Beautiful tuples |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2021-12-24 11:24:15 |
| 言語 | Python3 (3.14.7 + numpy 2.5.2 + scipy 1.18.0 + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 90 ms / 1,500 ms |
| + 408µs | |
| コード長 | 192 bytes |
| 記録 | |
| コンパイル時間 | 275 ms |
| コンパイル使用メモリ | 21,340 KB |
| 実行使用メモリ | 15,788 KB |
| 最終ジャッジ日時 | 2026-08-30 22:42:01 |
| 合計ジャッジ時間 | 2,771 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 15 |
ソースコード
A,B = map(int,input().split())
if B < A:
A,B = B,A
if B == A * 2:
print(3 * A)
elif B == A * 3:
print(A * 2)
elif A & 1 == 0 and B == A//2 * 3:
print(A//2)
else:
print(-1)