Discuss / Java / java 优化存储 hello被重复使用了

java 优化存储 hello被重复使用了

Topic source

兆云

#1 Created at ... [Delete] [Delete and Lock User]

// java 优化存储 hello被重复使用了

String s1 = "hello";

String s2 = "hellokitlt";

s2 = "hello";

System.out.println(s1 == s2); // true

System.out.println(s1.equals(s2)); // true


  • 1

Reply