Menu
Question Index
...

import java.awt.Component;
public class Ticker extends Component {
    public static void main(String[] args) {
        Ticker t = new Ticker();
        /* Missing Statements ? */
    }
}
Which two of the following statements, inserted independently, could legally be inserted into missing section of this code?
1. boolean test = (Component instanceof t);
2. boolean test = (t instanceof Ticker);
3. boolean test = t.instanceof(Ticker);
4. boolean test = (t instanceof Component);


2 and 3
2 and 4
1 and 4
1 and 3
None of the above

Doubts

Problems

Topic: Advanced Java Programming Concepts

Read this topic
Take test on this topic

0
Wrong
Score more than 2 points

© meritcampus 2019

All Rights Reserved.

Open In App