結果
問題 | No.342 一番ワロタww |
ユーザー | fal_rnd |
提出日時 | 2016-10-27 00:42:59 |
言語 | Java21 (openjdk 21) |
結果 |
WA
|
実行時間 | - |
コード長 | 378 bytes |
コンパイル時間 | 2,385 ms |
コンパイル使用メモリ | 76,816 KB |
実行使用メモリ | 41,484 KB |
最終ジャッジ日時 | 2024-05-03 06:14:23 |
合計ジャッジ時間 | 5,386 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | WA | - |
testcase_01 | AC | 117 ms
40,132 KB |
testcase_02 | AC | 129 ms
41,284 KB |
testcase_03 | AC | 130 ms
40,940 KB |
testcase_04 | AC | 130 ms
41,040 KB |
testcase_05 | AC | 129 ms
41,228 KB |
testcase_06 | WA | - |
testcase_07 | AC | 131 ms
41,332 KB |
testcase_08 | WA | - |
testcase_09 | AC | 114 ms
40,080 KB |
testcase_10 | AC | 115 ms
40,108 KB |
testcase_11 | AC | 132 ms
41,228 KB |
testcase_12 | AC | 131 ms
41,344 KB |
testcase_13 | AC | 129 ms
41,012 KB |
testcase_14 | WA | - |
testcase_15 | AC | 118 ms
40,276 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)); } } }