結果
| 問題 | No.436 ccw |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2026-10-20 19:54:14 |
| 言語 | C++23(gcc16) (gcc 16.2.0 + boost 1.92.0 + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 3 ms / 2,000 ms |
| + 649µs | |
| コード長 | 231 bytes |
| 記録 | |
| コンパイル時間 | 3,269 ms |
| コンパイル使用メモリ | 170,760 KB |
| 実行使用メモリ | 9,900 KB |
| 最終ジャッジ日時 | 2026-10-20 19:54:34 |
| 合計ジャッジ時間 | 3,919 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge4_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 23 |
ソースコード
#include <algorithm>
#include <iostream>
#include <string>
int main() {
using namespace std;
string s;
cin >> s;
int c = 0, w = 0;
for (auto e : s) { (e == 'c' ? c : w)++; }
cout << min(c - 1, w) << endl;
}