結果

問題 No.203 ゴールデン・ウィーク(1)
ユーザー uafr_cs
提出日時 2015-05-16 02:05:33
言語 Java
(openjdk 23)
結果
AC  
実行時間 121 ms / 1,000 ms
コード長 463 bytes
コンパイル時間 2,005 ms
コンパイル使用メモリ 76,904 KB
実行使用メモリ 54,256 KB
最終ジャッジ日時 2024-11-18 09:18:34
合計ジャッジ時間 6,096 ms
ジャッジサーバーID
(参考情報)
judge1 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 29
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Arrays;
import java.util.LinkedList;
import java.util.Scanner;

public class Main {
	
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		
		final char[] days = (sc.next() + sc.next()).toCharArray();
		
		int count = 0, max = 0;
		for(char c : days){
			if(c == 'o'){
				count++;
			}else{
				max = Math.max(max, count);
				count = 0;
			}
		}
		max = Math.max(max, count);
		
		System.out.println(max);
		
	}
	
}
0