結果
問題 | No.342 一番ワロタww |
ユーザー | fal_rnd |
提出日時 | 2016-10-27 00:42:59 |
言語 | Java21 (openjdk 21) |
結果 |
WA
|
実行時間 | - |
コード長 | 378 bytes |
コンパイル時間 | 1,835 ms |
コンパイル使用メモリ | 73,956 KB |
実行使用メモリ | 57,900 KB |
最終ジャッジ日時 | 2023-08-15 19:29:27 |
合計ジャッジ時間 | 4,604 ms |
ジャッジサーバーID (参考情報) |
judge15 / judge13 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | WA | - |
testcase_01 | AC | 106 ms
55,836 KB |
testcase_02 | AC | 110 ms
55,652 KB |
testcase_03 | AC | 107 ms
56,060 KB |
testcase_04 | AC | 105 ms
55,836 KB |
testcase_05 | AC | 107 ms
55,792 KB |
testcase_06 | WA | - |
testcase_07 | AC | 108 ms
56,196 KB |
testcase_08 | WA | - |
testcase_09 | AC | 114 ms
55,732 KB |
testcase_10 | AC | 115 ms
55,708 KB |
testcase_11 | AC | 114 ms
56,104 KB |
testcase_12 | AC | 108 ms
56,004 KB |
testcase_13 | AC | 105 ms
55,704 KB |
testcase_14 | WA | - |
testcase_15 | AC | 109 ms
55,844 KB |
testcase_16 | WA | - |
ソースコード
import java.util.Scanner; class A { static Scanner s = new Scanner(System.in); static String w = "w"; public static void main(String[] args) { String in = s.nextLine(); String ww = w; while(in.contains(ww+w)) { ww+=w; } String[] ss = in.split(ww); for(String s:ss) { if(!s.isEmpty()) System.out.println(s.substring(s.lastIndexOf(w)+1)); } } }