Question 71

Given the code fragment:

Which modification enables the code fragment to print TrueDone?
  • Question 72

    Given the code fragment:

    What is the result?
  • Question 73

    Given:
    public class TestField {
    int x;
    int y;
    public void doStuff(int x, int y) {
    this.x = x;
    y =this.y;
    }
    public void display() {
    System.out.print(x + " " + y + " : ");
    }
    public static void main(String[] args) {
    TestField m1 = new TestField();
    m1.x = 100;
    m1.y = 200;
    TestField m2 = new TestField();
    m2.doStuff(m1.x, m1.y);
    m1.display();
    m2.display();
    }
    }
    What is the result?
  • Question 74

    Which of the following can fill in the blank in this code to make it compile? (Select 2 options.)
  • Question 75

    Given:

    What is the result?