結果
| 問題 |
No.203 ゴールデン・ウィーク(1)
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2015-08-07 20:36:48 |
| 言語 | Java (openjdk 23) |
| 結果 |
AC
|
| 実行時間 | 121 ms / 1,000 ms |
| コード長 | 514 bytes |
| コンパイル時間 | 3,420 ms |
| コンパイル使用メモリ | 76,356 KB |
| 実行使用メモリ | 54,264 KB |
| 最終ジャッジ日時 | 2024-11-18 09:25:02 |
| 合計ジャッジ時間 | 7,223 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 29 |
ソースコード
import java.util.*;
public class gw{
public static void main(String... args){
Scanner scan = new Scanner(System.in);
String str1 = scan.next();
String str2 = scan.next();
System.out.println(calc(str1+str2));
}
public static int calc(String str){
int[] counter = new int[14];
for(int i = 0; i < counter.length;i++){
counter[i] = 0;
}
String[] h = str.split("x",0);
int max = 0;
for(int i = 0;i<h.length;i++){
if(h[i].length() > max){
max = h[i].length();
}
}
return max;
}
}