exam questions

Exam 98-361 All Questions

View all questions & answers for the 98-361 exam

Exam 98-361 topic 2 question 7 discussion

Actual exam question from Microsoft's 98-361
Question #: 7
Topic #: 2
[All 98-361 Questions]

You have a class named Truck that inherits from a base class named Vehicle. The Vehicle class includes a protected method named brake ().
How should you call the Truck Class implementation of the brake () method?

  • A. Mybase.brake ()
  • B. Truck.brakef)
  • C. Vehicle.brake()
  • D. Me.brake ()
Show Suggested Answer Hide Answer
Suggested Answer: A 🗳️
The MyBase keyword behaves like an object variable referring to the base class of the current instance of a class.MyBase is commonly used to access base class members that are overridden or shadowed in a derived class.

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
ccoutinho
Highly Voted 2 years, 3 months ago
If we want to call the method implementation in the Truck class (derived class), shouldn't we call Me.break() instead?
upvoted 6 times
...
misbelieving
Most Recent 8 months, 2 weeks ago
I think it's Truck.brake() if it's a static method, else Me.brake(). So probably Me.brake(), D
upvoted 2 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 ...