結果
| 問題 |
No.805 UMG
|
| コンテスト | |
| ユーザー |
25__toma
|
| 提出日時 | 2019-03-24 04:26:25 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
AC
|
| 実行時間 | 1,239 ms / 2,000 ms |
| コード長 | 226 bytes |
| コンパイル時間 | 284 ms |
| コンパイル使用メモリ | 12,544 KB |
| 実行使用メモリ | 10,624 KB |
| 最終ジャッジ日時 | 2024-11-18 13:33:43 |
| 合計ジャッジ時間 | 7,782 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 25 |
ソースコード
N=int(input())
S=input()
res=0
for le in range(1,N//2+1):
for st in range(N-le*2):
#print(st,le,S[st],S[st+le],S[st+le*2])
if S[st]=='U' and S[st+le]=='M' and S[st+le*2]=='G':
res+=1
print(res)
25__toma