結果

問題 No.292 芸名
ユーザー tubo28tubo28
提出日時 2015-11-13 21:32:39
言語 Java21
(openjdk 21)
結果
AC  
実行時間 129 ms / 2,000 ms
コード長 586 bytes
コンパイル時間 3,845 ms
コンパイル使用メモリ 71,972 KB
実行使用メモリ 56,164 KB
最終ジャッジ日時 2023-10-11 15:48:38
合計ジャッジ時間 4,598 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 126 ms
55,936 KB
testcase_01 AC 127 ms
55,704 KB
testcase_02 AC 127 ms
55,556 KB
testcase_03 AC 126 ms
55,948 KB
testcase_04 AC 127 ms
55,868 KB
testcase_05 AC 125 ms
55,976 KB
testcase_06 AC 126 ms
56,100 KB
testcase_07 AC 126 ms
56,164 KB
testcase_08 AC 125 ms
55,820 KB
testcase_09 AC 129 ms
55,896 KB
testcase_10 AC 129 ms
55,872 KB
testcase_11 AC 127 ms
55,940 KB
testcase_12 AC 124 ms
55,356 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

package yk725;

import java.util.*;
import java.lang.*;

public class Main {
	public static void main(String [] args){
		cin = new Scanner(System.in);
		(new Main()).run();
	}
	static Scanner cin;
	void run() {
		char[] S = cin.next().toCharArray();
		ArrayList<Character> arr = new ArrayList<>();
		for(char c : S){
			arr.add(c);
		}
		arr.set(cin.nextInt(), ' ');
		arr.set(cin.nextInt(), ' ');
		try { arr.remove((Character)' '); } catch(Exception e){}
		try { arr.remove((Character)' '); } catch(Exception e){}
		for(char c : arr) System.out.print(c);
		System.out.println();
	}
}
0