結果
| 問題 |
No.2073 Concon Substrings (Swap Version)
|
| コンテスト | |
| ユーザー |
👑 |
| 提出日時 | 2023-05-29 16:32:39 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
AC
|
| 実行時間 | 826 ms / 2,000 ms |
| コード長 | 152 bytes |
| コンパイル時間 | 487 ms |
| コンパイル使用メモリ | 12,416 KB |
| 実行使用メモリ | 12,032 KB |
| 最終ジャッジ日時 | 2024-12-28 09:57:53 |
| 合計ジャッジ時間 | 16,621 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 5 |
| other | AC * 37 |
ソースコード
I,R=input,range N=int(I())*3 S=I() a=0 s="con" for d in R(3): c=[0]*3 for i in R(N):c[i%3]+=S[i]==s[(i+d)%3] a+=min(c+[max(0,(N-a*3-d)//3)]) print(a)