Vidyalelo
Java Programming · Q10

Constructors and Methods

Programming · Java Programming · question 10

Q10

What is the correct syntax to call a method named "myMethod" from an object "myObject"?

A.
myObject.myMethod();
Answer
B.
myMethod.myObject();
C.
myMethod();
D.
myObject->myMethod();

Answer: Option A

Solution

Answer: Option A
No explanation is given for this question Let's Discuss on Board