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

© examsiri.com
Question : 55 of 84
 
Marks: +1, -0
class Patient {
   String name;
   public Patient(String name) {
      this.name = name;
   }
}
// And the code fragment:
8.public class Test {
9.      public static void main (String [] args) {
10.       List ps = new ArrayList ();
11.       Patient p2 = new Patient ("Mike");
12.       ps.add(p2);
13.
14.       // insert code here
15.
16.       if (f >= 0) {
17.          System.out.print ("Mike Found");
18.       }
19.    }
20. }


Which code fragment, when inserted at line 14, enables the code to print Mike Found?

Go to Question: