boolean

    java - isEmpty(), isBlank();

    isEmpty() 문자열의 길이가 0이라면 True를 리턴한다. isBlank() 문자열이 비어있거나, 빈 공백으로만 이루어져 있다면 True를 리턴한다. public class Main { public static void main(String[] args) { System.out.println("Hello".isEmpty() + "," + "Hello".isBlank()); // false, false System.out.println(" Hello ".isEmpty() + "," + " Hello ".isBlank()); // false, false System.out.println("".isEmpty() + "," + "".isBlank()); // true, true System.out.prin..