結果
| 問題 |
No.2766 Delicious Multiply Spice
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2024-05-31 21:23:40 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 467 bytes |
| コンパイル時間 | 325 ms |
| コンパイル使用メモリ | 81,984 KB |
| 実行使用メモリ | 184,836 KB |
| 最終ジャッジ日時 | 2024-12-20 22:13:40 |
| 合計ジャッジ時間 | 36,315 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 8 |
| other | AC * 23 TLE * 8 |
ソースコード
import collections,sys,math,functools,operator,itertools,bisect,heapq,decimal,string,time,random
sys.setrecursionlimit(10**9)
#sys.set_int_max_str_digits(0)
#input = sys.stdin.readline
#n = int(input())
#alist = list(map(int,input().split()))
#alist = []
#s = input()
n = int(input())
def calc(x,seq):
if x == n:
exit(print(''.join(seq)))
return
elif x > n:
return
calc(2*x + 1,seq + ['A'])
calc(3*x + 1,seq + ['B'])
calc(1,[])