Q.- Which three statements are true about the structure of a Java class?
A) A public class must have a main method.
B) Methods and fields are optional components of a class.
C) A class cannot have the same name as its field.
D) A class can have overloaded private constructors.
E) A class can have final static methods.
F) Fields need to be initialized before use.
⧪ please give your answer in a comment section.
A) A public class must have a main method.
B) Methods and fields are optional components of a class.
C) A class cannot have the same name as its field.
D) A class can have overloaded private constructors.
E) A class can have final static methods.
F) Fields need to be initialized before use.
⧪ please give your answer in a comment section.
8 Comments
Option A E F
ReplyDeleteA e f
ReplyDeleteb d e
ReplyDeleteB d e
ReplyDeleteA C F
ReplyDeleteA C F
ReplyDeleteA C F
ReplyDeleteCDE
ReplyDelete