Set - 8

Question 41 :

Can Java code be compiled to machine dependent executable file?

Answer :

Yes. There are many tools out there. If you did so, the generated exe file would be run in the specific platform, not cross-platform.


Question 42 :

Do not use the String contatenation operator in lengthy loops or other places where performance could suffer. Is that true?

Answer :

Yes.


Question 43 :

What method is used to specify a container's layout?

Answer :

The setLayout() method is used to specify a container's layout.


Question 44 :

Which containers use a FlowLayout as their default layout?

Answer :

The Panel and Applet classes use the FlowLayout as their default layout.


Question 45 :

What state does a thread enter when it terminates its processing?

Answer :

When a thread terminates its processing, it enters the dead state.