Microsoft
98-361 · Question #341
98-361 Question #341: Real Exam Question with Answer & Explanation
Sign in or unlock 98-361 to reveal the answer and full explanation for question #341. The question stem and answer options stay visible for context.
Question
You are developing code for a method that calculates the discount for the items sold. You name the method CalculateDiscount. The method defines a variable, percentValue of the type double. You need to make sure that percentValue is accessible only within the CalculateDiscount method. What access modifier should you use when defining the percentValue variable?
Options
- Aprivate
- Bprotected
- Cinternal
- Dpublic
Unlock 98-361 to see the answer
You've previewed enough free 98-361 questions. Unlock 98-361 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.