結果

問題 No.292 芸名
ユーザー shinwisteria
提出日時 2018-02-16 23:24:32
言語 Java
(openjdk 23)
結果
AC  
実行時間 114 ms / 2,000 ms
コード長 480 bytes
コンパイル時間 3,196 ms
コンパイル使用メモリ 76,360 KB
実行使用メモリ 41,548 KB
最終ジャッジ日時 2024-06-23 06:12:29
合計ジャッジ時間 5,888 ms
ジャッジサーバーID
(参考情報)
judge4 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 10
権限があれば一括ダウンロードができます

ソースコード

diff #

package m.shin;
import java.util.Scanner;
public class Con292 {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner s = new Scanner(System.in);
		String str = s.next();
		int t = s.nextInt() , u = s.nextInt();
		s.close();
		int p = Math.max(t, u) , q = Math.min(t, u);

		str = str.substring(0, p) + str.substring(p+1);
		if(p != q){
			str = str.substring(0, q) + str.substring(q+1);
		}
		System.out.println(str);
	}

}
0