Serendipity Booksellers has a book club that awards points to its customers based on the number of books purchased every month, The points are awarded as follows 1.If a customer purchases 0 books, he or she earns points 0 If a customer purchases 1 books, he or she earns points 5 If a customer purchases 2 books, he or she earns 15 points If a customer purchases 3 books, he or she earns 30 points If a customer purchases 4 or more books he or she earns 60 points Design a program using pseudocode that asks the user to enter the number of books that he or she has purchased this month and displays the number of points awarded .
Serendipity Booksellers has a book club that awards points to its customers based on the number of books purchased every month, The points are awarded as follows
1.If a customer purchases 0 books, he or she earns points 0
If a customer purchases 1 books, he or she earns points 5
If a customer purchases 2 books, he or she earns 15 points
If a customer purchases 3 books, he or she earns 30 points
If a customer purchases 4 or more books he or she earns 60 points
Design a program using pseudocode that asks the user to enter the number of books that he or she has purchased this month and displays the number of points awarded .
Here are some necessary parameters to follow to help solve the problem. Please write line numbers before each line of the
- Create a main module. It should declare one local variable and call two other modules
- Create a module to get input from the software user
- Create a module to print out the answer.
Use the following example format when structuring the pseduocode. Unless noted with **
Module Main ()
//Declare a varaiable for the
//number of cups needed
Declare Ral cupsNeeded
//Display An intro Message
Call showIntro()
//Get the number of cups
Call getCups(cupsNeeded)
End Module
Module getCups(Real Ref cups)
Display " Enter the amount of cups"
Input cups
End Module
Trending now
This is a popular solution!
Step by step
Solved in 2 steps with 3 images