2015-01-18から1日間の記事一覧
リテラル文字列について、 同じ文字列の場合は、同一インスタンスを参照する。 public static void main(String[] args) { String str1 = "str"; String str2 = "str"; if(str1==str2){ System.out.println("true"); }else{ System.out.println("false"); } …
リテラル文字列について、 同じ文字列の場合は、同一インスタンスを参照する。 public static void main(String[] args) { String str1 = "str"; String str2 = "str"; if(str1==str2){ System.out.println("true"); }else{ System.out.println("false"); } …