Question: For the Decision Table questions below, use the following function: int discountPercent ( double price, int pastOrderCount ) returns the percent discount to be given,
For the Decision Table questions below, use the following function:
int discountPercent
double price, int pastOrderCount
returns the percent discount to be given, when given the price of the merchandise, and the number of orders the customer has placed in the past.
Past Order Count
Percent Discount
pastOrderCount
pastOrderCount
pastOrderCount
Orders over $
are given an automatic, additional
discount
Path Testing
For the Path Testing questions below, use the following code:
public void play
String src
null;
String dest
null;
LinkedList srcPile
null;
boolean gameOver
false;
while
gameOver
displayTableau
;
do
System.out.print
Move top card from
D
W
W
W
W
or Q to quit
:
;
src
in
nextLine
;
if
src
toUpperCase
charAt
Q
gameOver
true;
while
gameOver &&
srcPile
getSrcPile
src
null
;
if
gameOver
System.out.print
to
F
F
F
F
W
W
W
W
:
;
dest
in
nextLine
;
addToDestPile
dest
srcPile
;
gameOver
checkForGameOver
gameOver
;
Rule Counts
What is the maximum number of rules for this function if we do not collapse any.
Show your Decision Table from the Base Assignment
Annotate the columns with the number of rules each covers.
DDPath Node Case Definitions
For the DDPath Graph create and add the Case Definition to your table for each node in that DDPath Graph.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
