結果

問題 No.203 ゴールデン・ウィーク(1)
ユーザー yun_appyun_app
提出日時 2016-05-12 11:54:00
言語 Java21
(openjdk 21)
結果
AC  
実行時間 55 ms / 1,000 ms
コード長 847 bytes
コンパイル時間 2,089 ms
コンパイル使用メモリ 74,356 KB
実行使用メモリ 37,272 KB
最終ジャッジ日時 2024-04-29 08:05:05
合計ジャッジ時間 4,540 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 52 ms
37,072 KB
testcase_01 AC 52 ms
36,948 KB
testcase_02 AC 50 ms
36,960 KB
testcase_03 AC 51 ms
36,612 KB
testcase_04 AC 52 ms
36,900 KB
testcase_05 AC 51 ms
36,856 KB
testcase_06 AC 52 ms
37,052 KB
testcase_07 AC 52 ms
36,984 KB
testcase_08 AC 55 ms
36,604 KB
testcase_09 AC 52 ms
37,196 KB
testcase_10 AC 54 ms
36,992 KB
testcase_11 AC 52 ms
37,164 KB
testcase_12 AC 52 ms
37,256 KB
testcase_13 AC 52 ms
37,032 KB
testcase_14 AC 54 ms
37,124 KB
testcase_15 AC 52 ms
37,104 KB
testcase_16 AC 54 ms
36,852 KB
testcase_17 AC 52 ms
36,968 KB
testcase_18 AC 52 ms
37,136 KB
testcase_19 AC 52 ms
37,116 KB
testcase_20 AC 51 ms
37,076 KB
testcase_21 AC 51 ms
37,272 KB
testcase_22 AC 52 ms
37,136 KB
testcase_23 AC 51 ms
36,960 KB
testcase_24 AC 51 ms
37,108 KB
testcase_25 AC 52 ms
37,136 KB
testcase_26 AC 51 ms
37,076 KB
testcase_27 AC 51 ms
37,124 KB
testcase_28 AC 50 ms
36,980 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

/* package whatever; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
    public static void main (String[] args) throws java.lang.Exception
    {
        // your code goes here
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String line = br.readLine();
        int max = 0;
        int cnt = 0;
        while(line!=null){
            for(String st:line.split("")){
                if(st.equals("o")){
                    cnt++;
                }else{
                    max = Math.max(max,cnt);
                    cnt = 0;
                }
            }
            line = br.readLine();
        }
        max = Math.max(max,cnt);
        System.out.println(max);
    }

}
0