結果
問題 | No.436 ccw |
ユーザー |
![]() |
提出日時 | 2016-10-31 00:17:35 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 3 ms / 2,000 ms |
コード長 | 249 bytes |
コンパイル時間 | 573 ms |
コンパイル使用メモリ | 58,660 KB |
実行使用メモリ | 6,820 KB |
最終ジャッジ日時 | 2024-11-24 23:53:14 |
合計ジャッジ時間 | 1,463 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 24 |
ソースコード
#include <iostream> #include <sstream> #include <algorithm> int main(int argc, char *argv[]) { std::string s; std::cin >> s; int pos = s.find('w'); int ans = std::min(pos - 1, (int)s.length() - pos); std::cout << ans << std::endl; return 0; }