結果

問題 No.436 ccw
ユーザー tsunabittsunabit
提出日時 2019-06-08 02:42:28
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 471 bytes
コンパイル時間 3,052 ms
コンパイル使用メモリ 78,268 KB
実行使用メモリ 42,384 KB
最終ジャッジ日時 2024-04-15 19:28:43
合計ジャッジ時間 7,368 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 117 ms
41,248 KB
testcase_01 AC 104 ms
39,892 KB
testcase_02 AC 110 ms
41,100 KB
testcase_03 AC 113 ms
41,200 KB
testcase_04 AC 100 ms
40,168 KB
testcase_05 AC 113 ms
41,172 KB
testcase_06 WA -
testcase_07 AC 111 ms
41,616 KB
testcase_08 AC 115 ms
41,300 KB
testcase_09 AC 111 ms
41,028 KB
testcase_10 AC 103 ms
39,912 KB
testcase_11 AC 104 ms
40,116 KB
testcase_12 AC 112 ms
40,896 KB
testcase_13 AC 103 ms
40,064 KB
testcase_14 AC 118 ms
41,092 KB
testcase_15 AC 116 ms
41,124 KB
testcase_16 AC 127 ms
41,352 KB
testcase_17 AC 117 ms
41,480 KB
testcase_18 AC 114 ms
40,336 KB
testcase_19 AC 133 ms
41,368 KB
testcase_20 AC 125 ms
40,644 KB
testcase_21 AC 173 ms
42,384 KB
testcase_22 AC 181 ms
42,224 KB
testcase_23 AC 183 ms
42,208 KB
testcase_24 AC 163 ms
42,144 KB
testcase_25 AC 175 ms
42,280 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;
import java.math.*;

public class No436 {
    public static void main(String[] args) {
        // 標準入力から読み込む際に、Scannerオブジェクトを使う。
        Scanner s = new Scanner(System.in);
        String str = s.next();
        int b = str.indexOf("ccw");
        
        if(b < str.length() / 2) {
        	System.out.println(b + 1);
        }else {
        	System.out.println(str.length() - b - 2);
        }
    }
}
0