You have created a simple Frame and overridden the paint method as follows public void paint(Graphics g){ g.drawString("Dolly",50,10);}What will be the result when you attempt to compile and run the program?

A) The string "Dolly" will be displayed at the centre of the frame
B) An error at compilation complaining at the signature of the paint method
C) The lower part of the word Dolly will be seen at the top of the form, with the top hidden.
D) The string "Dolly" will be shown at the bottom of the form

Showing Answers 1 - 2 of 2 Answers

chandan

  • Oct 6th, 2006
 

Ans:A

 drawString () metod is method of the graphics class

  Was this answer useful?  Yes

MANISHA PATHAK

  • Oct 26th, 2006
 

Ans) C

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions