Java SE 8 Programmer 1Z0–808 Practice Full Test 1

© examsiri.com
Question : 31 of 84
 
Marks: +1, -0
Given the definitions of the MyString class and the Test class: //MyString.java
package pi;
class MyString {
  String msg;
  MyString(String msg) {
    this.msg = msg;
  }
}
//Test.java
package pi;
public class Test {
  public static void main (String[] args) {
    System.out.println("Hello " + new StringBuilder("Java SE 8"));
    System.out.println ("Hello " + new MyString ("Java SE 8"));
  }
}
What is the result?
Go to Question: