Trim - Java Quiz Question


What will be the output of the following program?

public class TrimTest {
    public static void main(String s[])
    {
        String input = "MeritCampus ";
        System.out.println(input.trim().equals(input));
    }
}


A
true
B
false
C
Compilation Error
D
Runtime Error