結果
| 問題 | No.1819 Mirrored 2 |
| コンテスト | |
| ユーザー |
Sumitacchan
|
| 提出日時 | 2022-01-21 22:09:48 |
| 言語 | PyPy3 (7.3.23 + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 134 ms / 2,000 ms |
| + 375µs | |
| コード長 | 377 bytes |
| 記録 | |
| コンパイル時間 | 63 ms |
| コンパイル使用メモリ | 81,772 KB |
| 実行使用メモリ | 84,128 KB |
| 最終ジャッジ日時 | 2026-09-30 04:45:42 |
| 合計ジャッジ時間 | 4,174 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 26 |
ソースコード
# -*- coding: utf-8 -*-
import random
def rev(N):
s = str(N)
s = s[::-1]
return int(s)
if __name__ == '__main__':
P, Q, x, y = map(int, input().split())
while True:
k = random.randint(0, 10**12)
N = k * Q + y
if N % 10 == 0:
continue
if rev(N) % P == x:
ans = rev(N)
break
print(ans)
Sumitacchan