exam questions

Exam MB-500 All Questions

View all questions & answers for the MB-500 exam

Exam MB-500 topic 3 question 31 discussion

Actual exam question from Microsoft's MB-500
Question #: 31
Topic #: 3
[All MB-500 Questions]

Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.
After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.
You must extend the class SalesLineType and add a new method that returns the day of week for the system's current date as an integer value.
You need to create a class that extends SalesLineType and adds the new method.
Solution: You create the following code:

Does the solution meet the goal?

  • A. Yes
  • B. No
Show Suggested Answer Hide Answer
Suggested Answer: B 🗳️

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
makarsharl
Highly Voted 2 years, 4 months ago
Selected Answer: B
class declaration should be final not public
upvoted 19 times
...
Ariston
Highly Voted 3 years, 10 months ago
This is correct A
upvoted 13 times
...
8933e4c
Most Recent 8 months, 3 weeks ago
Selected Answer: B
Class must be final not public.
upvoted 1 times
...
smithlaod
1 year, 4 months ago
Selected Answer: A
An extension class should be final.
upvoted 1 times
smithlaod
1 year, 4 months ago
Wrong voted. B is what I selected.
upvoted 1 times
...
...
Nooby69
1 year, 5 months ago
Selected Answer: B
EXTENSION CLASS SHOULD ALWAYS BE FINAL AND NOT PUBLIC
upvoted 1 times
...
theCoder1
1 year, 10 months ago
Correct B .100%. not correct without final class
upvoted 3 times
...
Ganga425
2 years ago
Selected Answer: B
final keyword missing from declaration
upvoted 3 times
...
DanSinbad
2 years, 1 month ago
Selected Answer: B
no final
upvoted 3 times
...
Random2212
2 years, 2 months ago
Selected Answer: B
Chat gpt says is not correct. Class should be final and method should not be static
upvoted 1 times
...
testara
2 years, 2 months ago
Correct B .100%.
upvoted 2 times
...
MaximeC
2 years, 4 months ago
Selected Answer: B
Class should be final
upvoted 2 times
...
Prollyx
2 years, 4 months ago
Selected Answer: B
discussion was for another question than is now, so now, correct answer is B
upvoted 1 times
...
SaadxD
2 years, 5 months ago
Selected Answer: B
B ! because in COC you cannot use Public class . class should be final or internal-final
upvoted 3 times
...
yuri_rusanov
2 years, 6 months ago
The discussion section is so messed up talking about different questions to the point it's not even remotely useful.
upvoted 1 times
...
WahdatSaid
2 years, 7 months ago
Answer is B ! because in COC you cannot use Public class . class should be final or internal-final
upvoted 2 times
yuri_rusanov
2 years, 6 months ago
This is not COC. It's a new method.
upvoted 1 times
...
...
natalyV
2 years, 10 months ago
The name of class in the example is mySalesLineType, it should be simply SalesLineType, so the answer is B
upvoted 1 times
...
Prollyx
3 years, 2 months ago
Selected Answer: A
Solution is correct, when you are asked to extend something existing you need to make an extension.
upvoted 3 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 ...