結果

問題 No.203 ゴールデン・ウィーク(1)
ユーザー FVRChanFVRChan
提出日時 2017-10-02 21:21:01
言語 Java21
(openjdk 21)
結果
AC  
実行時間 126 ms / 1,000 ms
コード長 419 bytes
コンパイル時間 2,189 ms
コンパイル使用メモリ 73,900 KB
実行使用メモリ 56,348 KB
最終ジャッジ日時 2023-08-11 16:37:12
合計ジャッジ時間 7,085 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 126 ms
55,824 KB
testcase_01 AC 125 ms
55,748 KB
testcase_02 AC 124 ms
55,772 KB
testcase_03 AC 124 ms
55,900 KB
testcase_04 AC 126 ms
55,660 KB
testcase_05 AC 123 ms
55,752 KB
testcase_06 AC 124 ms
55,936 KB
testcase_07 AC 124 ms
55,688 KB
testcase_08 AC 121 ms
56,008 KB
testcase_09 AC 125 ms
53,888 KB
testcase_10 AC 122 ms
55,748 KB
testcase_11 AC 123 ms
55,728 KB
testcase_12 AC 122 ms
55,724 KB
testcase_13 AC 122 ms
55,672 KB
testcase_14 AC 122 ms
56,120 KB
testcase_15 AC 121 ms
55,984 KB
testcase_16 AC 121 ms
55,884 KB
testcase_17 AC 122 ms
55,668 KB
testcase_18 AC 121 ms
55,880 KB
testcase_19 AC 123 ms
55,880 KB
testcase_20 AC 122 ms
55,884 KB
testcase_21 AC 121 ms
55,440 KB
testcase_22 AC 120 ms
55,972 KB
testcase_23 AC 125 ms
56,108 KB
testcase_24 AC 123 ms
55,816 KB
testcase_25 AC 123 ms
56,348 KB
testcase_26 AC 121 ms
55,776 KB
testcase_27 AC 122 ms
55,836 KB
testcase_28 AC 124 ms
55,848 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;
public class Main{
	private static Scanner sc=new Scanner(System.in);
	public static void main(String args[])throws Exception{
		char are[]=(sc.nextLine()+sc.nextLine()).toCharArray();
		int max=0,counter=0;
		for(char element:are){
			if(element == 'o'){
				counter++;
			}else{
				max=Math.max(max,counter);
				counter=0;
			}
		}max=Math.max(max,counter);
		System.out.println(max);
	}
}
0