結果
| 問題 | No.805 UMG |
| コンテスト | |
| ユーザー |
sasa
|
| 提出日時 | 2025-03-18 17:39:48 |
| 言語 | C++14 (gcc 15.2.0 + boost 1.90.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 324 bytes |
| 記録 | |
| コンパイル時間 | 92 ms |
| コンパイル使用メモリ | 39,552 KB |
| 実行使用メモリ | 5,760 KB |
| 最終ジャッジ日時 | 2026-07-07 06:15:31 |
| 合計ジャッジ時間 | 1,476 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 WA * 2 |
| other | AC * 5 WA * 20 |
ソースコード
#include <stdio.h>
#include <string.h>
int main(void){
char str[5000];
scanf("%s",str);
int len = strlen(str);
int count = 0;
for(int i = 0;i < len - 2;i ++){
for(int j = i;j < i + ((len - i) / 2);j ++){
if(str[i] == 'U' && str[j] == 'M' && str[j * 2] == 'G'){
count++;
}
}
}
printf("%d",count);
}
sasa