結果
問題 | No.1894 Delete AB |
ユーザー |
|
提出日時 | 2023-02-02 21:02:48 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
WA
|
実行時間 | - |
コード長 | 418 bytes |
コンパイル時間 | 71 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 21,424 KB |
最終ジャッジ日時 | 2024-07-02 07:45:51 |
合計ジャッジ時間 | 6,114 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 |
other | WA * 5 RE * 7 TLE * 1 -- * 1 |
ソースコード
n=int(input())for i in range(n):m=int(input())a=input()i=1while 1>0:l=list(map(str,a.strip("")))if len(l)==1:breakif l[i-1]<l[i]:l.pop(i-1)l.pop(i-1)b="".join(l)if a>b:breakelse:if a==b:i+=1else:i=0a=bprint(a)