結果

問題 No.203 ゴールデン・ウィーク(1)
ユーザー nCk_cvnCk_cv
提出日時 2015-11-28 01:16:22
言語 Java21
(openjdk 21)
結果
AC  
実行時間 155 ms / 1,000 ms
コード長 517 bytes
コンパイル時間 2,293 ms
コンパイル使用メモリ 82,136 KB
実行使用メモリ 42,524 KB
最終ジャッジ日時 2024-04-29 07:59:16
合計ジャッジ時間 7,968 ms
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 134 ms
42,104 KB
testcase_01 AC 149 ms
42,296 KB
testcase_02 AC 143 ms
42,400 KB
testcase_03 AC 149 ms
42,180 KB
testcase_04 AC 152 ms
42,160 KB
testcase_05 AC 137 ms
42,204 KB
testcase_06 AC 152 ms
41,948 KB
testcase_07 AC 151 ms
42,196 KB
testcase_08 AC 153 ms
42,432 KB
testcase_09 AC 151 ms
42,524 KB
testcase_10 AC 138 ms
42,376 KB
testcase_11 AC 149 ms
42,236 KB
testcase_12 AC 148 ms
42,212 KB
testcase_13 AC 155 ms
42,088 KB
testcase_14 AC 147 ms
42,076 KB
testcase_15 AC 153 ms
42,224 KB
testcase_16 AC 138 ms
42,040 KB
testcase_17 AC 146 ms
42,068 KB
testcase_18 AC 147 ms
42,080 KB
testcase_19 AC 135 ms
42,212 KB
testcase_20 AC 137 ms
42,480 KB
testcase_21 AC 150 ms
42,056 KB
testcase_22 AC 130 ms
42,432 KB
testcase_23 AC 145 ms
42,344 KB
testcase_24 AC 125 ms
41,996 KB
testcase_25 AC 134 ms
42,244 KB
testcase_26 AC 127 ms
42,292 KB
testcase_27 AC 146 ms
42,100 KB
testcase_28 AC 144 ms
42,380 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;
import java.util.Map.Entry;
import java.math.*;
import java.awt.geom.*;
import java.io.*;
      
      
public class Main {	

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String in = sc.next() + sc.next() + "x";
		
		char[] str = in.toCharArray();
		int MAX = 0;
		for(int i = 0; i < str.length; i++) {
			for(int j = 0; j < str.length; j++) {
				if(str[i + j] != 'o') {
					MAX = Math.max(MAX, j);
					break;
				}
			}
		}
		System.out.println(MAX);
	}
}
0