結果

問題 No.795 Restrictions!!!!!!!!!!!!!!
ユーザー キョウチクキョウチク
提出日時 2022-05-14 10:11:33
言語 Java21
(openjdk 21)
結果
AC  
実行時間 204 ms / 2,000 ms
コード長 357 bytes
コンパイル時間 2,074 ms
コンパイル使用メモリ 71,772 KB
実行使用メモリ 57,096 KB
最終ジャッジ日時 2023-09-30 00:25:32
合計ジャッジ時間 7,190 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 197 ms
56,824 KB
testcase_01 AC 204 ms
56,680 KB
testcase_02 AC 194 ms
56,612 KB
testcase_03 AC 195 ms
57,040 KB
testcase_04 AC 194 ms
56,872 KB
testcase_05 AC 196 ms
56,844 KB
testcase_06 AC 199 ms
56,812 KB
testcase_07 AC 195 ms
56,372 KB
testcase_08 AC 197 ms
56,744 KB
testcase_09 AC 196 ms
56,472 KB
testcase_10 AC 202 ms
56,164 KB
testcase_11 AC 193 ms
56,812 KB
testcase_12 AC 199 ms
56,860 KB
testcase_13 AC 203 ms
56,424 KB
testcase_14 AC 201 ms
56,500 KB
testcase_15 AC 195 ms
57,096 KB
testcase_16 AC 199 ms
56,896 KB
testcase_17 AC 198 ms
54,704 KB
testcase_18 AC 199 ms
56,728 KB
testcase_19 AC 195 ms
57,092 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;
public class Main{
  public static void main(String[] args){
    Scanner sc=new Scanner(System.in);
    String line;
    line=sc.nextLine();
    String n=line;
    line=sc.nextLine();
    String m=line;
    if(n.equals(m.substring(0,m.length()-1))){
      System.out.println("Yes");
    }else{
      System.out.println("No");
    }
  }
}
0