結果

問題 No.203 ゴールデン・ウィーク(1)
ユーザー ぴろずぴろず
提出日時 2015-05-08 22:22:08
言語 Java21
(openjdk 21)
結果
AC  
実行時間 128 ms / 1,000 ms
コード長 476 bytes
コンパイル時間 2,001 ms
コンパイル使用メモリ 74,300 KB
実行使用メモリ 41,312 KB
最終ジャッジ日時 2024-04-29 07:32:22
合計ジャッジ時間 6,505 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 123 ms
41,180 KB
testcase_01 AC 121 ms
40,752 KB
testcase_02 AC 122 ms
40,956 KB
testcase_03 AC 121 ms
41,276 KB
testcase_04 AC 126 ms
41,024 KB
testcase_05 AC 109 ms
40,272 KB
testcase_06 AC 126 ms
40,996 KB
testcase_07 AC 108 ms
39,960 KB
testcase_08 AC 121 ms
41,012 KB
testcase_09 AC 124 ms
40,996 KB
testcase_10 AC 109 ms
40,164 KB
testcase_11 AC 128 ms
40,968 KB
testcase_12 AC 124 ms
41,032 KB
testcase_13 AC 122 ms
41,136 KB
testcase_14 AC 122 ms
41,036 KB
testcase_15 AC 123 ms
40,932 KB
testcase_16 AC 110 ms
39,996 KB
testcase_17 AC 109 ms
39,760 KB
testcase_18 AC 109 ms
40,288 KB
testcase_19 AC 127 ms
41,312 KB
testcase_20 AC 125 ms
41,148 KB
testcase_21 AC 123 ms
41,108 KB
testcase_22 AC 110 ms
40,092 KB
testcase_23 AC 123 ms
41,236 KB
testcase_24 AC 123 ms
41,012 KB
testcase_25 AC 110 ms
39,760 KB
testcase_26 AC 128 ms
40,880 KB
testcase_27 AC 122 ms
40,944 KB
testcase_28 AC 121 ms
41,004 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

package no203;

import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		char[] c = new char[14];
		for(int i=0;i<2;i++) {
			char[] s = sc.next().toCharArray();
			for(int j=0;j<7;j++) {
				c[i*7+j] = s[j];
			}
		}
		int max = 0;
		int now = 0;
		for(int i=0;i<14;i++) {
			if (c[i] == 'o') {
				now++;
				max = Math.max(max, now);
			}else{
				now = 0;
			}
		}
		System.out.println(max);
	}

}
0