exam questions

Exam 98-388 All Questions

View all questions & answers for the 98-388 exam

Exam 98-388 topic 1 question 40 discussion

Actual exam question from Microsoft's 98-388
Question #: 40
Topic #: 1
[All 98-388 Questions]

The question requires that you evaluate the underlined text to determine if it is correct.
You have the following class definition:

The logError method can be invoked by code in all classes in the same package as the Logger class.
Review the underlined text. If it makes the statement correct, select "No change is needed." If the statement is incorrect, select the answer choice that makes the statement correct.

  • A. No change is needed
  • B. only by the Logger class
  • C. only by the Logger class and classes in the same package that inherit from it
  • D. by all classes in all packages
Show Suggested Answer Hide Answer
Suggested Answer: C 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
BiDzej
Highly Voted 4 years, 9 months ago
It's about class visiblity, there is no 'public' before 'class' keyword so it's visible only to classes in the same package. "By default, the classes visibility is package private, i.e. only visible for classes in the same package." Valid answer is then A
upvoted 12 times
...
mtmoore
Most Recent 4 years, 10 months ago
The correct answer is D.
upvoted 4 times
...
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.

SaveCancel
Loading ...