강의 1
소스코드
public class StringApp { public static void main(String[] args) { // Character VS String System.out.println("Hello World"); // String System.out.println('H'); // Character System.out.println("H"); System.out.println("Hello " + "World"); // new line System.out.println("Hello \nWorld"); // escape System.out.println("Hello \"World\"");// Hello "World" } }
강의 1
소스코드
public class StringOperation { public static void main(String[] args) { System.out.println("Hello World".length()); // 11 System.out.println("Hello, [[[name]]] ... bye. ".replace("[[[name]]]", "duru")); } }