Question
import java.awt.*;
import java.applet.*;
public class myapplet extends Applet
{
Graphic g;
g.drawString("A Simple Applet", 20, 20);
}
a.
20
b.
Default value
c.
Compilation Error
d.
Runtime Error
Posted under Java Programming
Engage with the Community - Add Your Comment
Confused About the Answer? Ask for Details Here.
Know the Explanation? Add it Here.
Q. What is the length of the application box made by this program?
Similar Questions
Discover Related MCQs
Q. An applet is a Java class that extends the
View solution
Q. Applets are designed to be embedded within an __________.
View solution
Q. Which of the following is required to view an applet?
View solution
Q. Which method is automatically called after the browser calls the init method?
View solution
Q. Which method is only called when the browser shuts down normally?
View solution
Q. Which method causes the audio clip to replay continually?
View solution
Q. paint() is an abstract method defined in AWT.
View solution
Q. ___________ method is defined in Graphics class, it is used to output a string in an applet.
View solution
Q. Java I/O is used to process the?
View solution
Q. Can we perform file handling in Java by Java I/O API?
View solution
Q. In java, how many streams are created for us automatically?
View solution
Q. Which method is used to write a byte to the current output stream?
View solution
Q. Which method is used to write an array of byte to the current output stream?
View solution
Q. ObjectFilter is a member of java.io package.
View solution
Q. ___________ returns true if called on a file and returns false when called on a directory.
View solution
Suggested Topics
Are you eager to expand your knowledge beyond Java Programming? We've curated a selection of related categories that you might find intriguing.
Click on the categories below to discover a wealth of MCQs and enrich your understanding of Computer Science. Happy exploring!