Solved

A Store Applies a 15 Percent Service Charge on All

Question 61

Multiple Choice

A store applies a 15 percent service charge on all items with a price of at least $150. No service charge is otherwise applicable. Which of the following DOES NOT correctly compute the service charge?


A) double serviceCharge = 0;
If (cost >= 150)
{
ServiceCharge = 0.15 * cost;
}
B) double serviceCharge = 0.15 * cost;
If (cost <= 150)
{
ServiceCharge = 0;
}
C) double serviceCharge;
If (cost < 150)
{
ServiceCharge = 0;
}
Else
{
ServiceCharge = 0.15 * cost;
}
D) double serviceCharge = 15;
If (cost >= 150)
{
ServiceCharge = 0.15 * cost;
}
Else
{
ServiceCharge = 0;
}

Correct Answer:

verifed

Verified

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions

Unlock this Answer For Free Now!

View this answer and more for free by performing one of the following actions

qr-code

Scan the QR code to install the App and get 2 free unlocks

upload documents

Unlock quizzes for free by uploading documents