結果

問題 No.256 桁の数字を入れ替え (2)
ユーザー DexctersuDexctersu
提出日時 2018-01-13 00:45:26
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
RE  
(最新)
AC  
(最初)
実行時間 -
コード長 173 bytes
コンパイル時間 287 ms
コンパイル使用メモリ 10,512 KB
実行使用メモリ 9,268 KB
最終ジャッジ日時 2023-08-25 15:59:00
合計ジャッジ時間 1,647 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
7,856 KB
testcase_01 AC 15 ms
7,912 KB
testcase_02 RE -
testcase_03 RE -
権限があれば一括ダウンロードができます

ソースコード

diff #

n=list(map(int,input()))
n.sort()
ans=""
anw=""
for i in n:
    ans+=str(i)
n.reverse()
for i in n:
    anw+=str(i)
if int(ans)<int(anw):
    print(anw)
else:
    print(ans)
0