結果

問題 No.203 ゴールデン・ウィーク(1)
ユーザー TwinkleStar74TwinkleStar74
提出日時 2017-10-29 03:00:01
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 607 bytes
コンパイル時間 2,681 ms
コンパイル使用メモリ 71,472 KB
実行使用メモリ 49,888 KB
最終ジャッジ日時 2023-08-14 09:09:34
合計ジャッジ時間 5,420 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 38 ms
49,780 KB
testcase_02 AC 39 ms
49,164 KB
testcase_03 WA -
testcase_04 AC 39 ms
49,088 KB
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
testcase_10 AC 40 ms
49,248 KB
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 AC 39 ms
49,328 KB
testcase_17 WA -
testcase_18 WA -
testcase_19 WA -
testcase_20 WA -
testcase_21 WA -
testcase_22 AC 39 ms
49,196 KB
testcase_23 WA -
testcase_24 WA -
testcase_25 WA -
testcase_26 AC 39 ms
49,308 KB
testcase_27 AC 39 ms
49,292 KB
testcase_28 AC 39 ms
49,124 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class No203 {
	public static void main(String[] args) throws IOException{
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String str = br.readLine();
		String str2 = br.readLine();
		int count = 0;
		count = check(str, count);
		count = check(str2, count);
		System.out.println(count);
	}
	
	public static int check(String s, int n){
		int ans = n;
		char[] day = s.toCharArray();
		for(int i=0; i < 7; i++){
			if(day[i] == 'o') ans++;
			else ans = 0;
		}
		return ans;
	}
}
0