C is the only correct answer, beaucse line n1 is inside the class "Messenger", it will call the local class function of the instance. So Basicalle "writeMsg();" in position n1 is a short version of "this.writeMsg();".
C is the correct answer because, a method can access another method within a class directly. writeMsg() is an instance method and not a static method.
B is incorrect because Messenger.writeMsg() implies as if writeMsg() is a static method. In order B to be correct, keyword "static" should be explicitly declared in writeMsg() method.
Se puede llamar el un método publico dentro de otro método dentro de la misma clase
upvoted 1 times
...
This section is not available anymore. Please use the main Exam Page.1z0-811 Exam Questions
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
PLSnoob
1 month, 2 weeks agofacudtd
3 months agoelectri
4 months agosupercoder
5 months, 2 weeks agoRoss_2023
7 months agofalchetto
11 months, 1 week agoOlha88
1 year agoyonathanmartinez
1 year, 4 months ago