Database System Concepts
7th Edition
ISBN: 9780078022159
Author: Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher: McGraw-Hill Education
expand_more
expand_more
format_list_bulleted
Concept explainers
Question
-
- Calculate the profit (profit) as the retail price minus the wholesale price
- Calculate the sale price (salePrice) as 25 percent deducted from the retail price
- Calculate the sale profit (saleProfit) as the sale price minus the wholesale price.
-
Execute the program by clicking the Run button. Your output should be as follows:
Item Name: TV Stand Retail Price: $325 Wholesale Price: $200 Profit: $125 Sale Price: $243.75 Sale Profit: $43.75
Expert Solution
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
This is a popular solution
Trending nowThis is a popular solution!
Step by stepSolved in 3 steps with 1 images
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Similar questions
- The following steps calculates the discounted sales price of a user inputted retail amount. 1. Write a line of code to set the discount to 15%. Use discount as the variable.arrow_forwardWhich statement will display The price is 4.99 Assume a variable called price stores the value 4.99. A. print(The price is 4.99) B. print("The price is" , price) C. print('The price is price') D. print('The price is ', Price)arrow_forwardAn online music and apps store offers all apps for 3$ each and all songs for 7$ each. The store requires members to prepay any amount of money they wish, and then download as many apps or as many songs accordingly. You are required to write a program that would ask the user for the amount that he/she will pay, then display two messages indicating: -the maximum number of apps that can be downloaded, and how much funds will remain in the account after that, if any. -the maximum number of songs that can be downloaded, the number of apps that can be downloaded after that if funds allow, and how much funds will remain in the account after that, if any. Notice the parenthesis in app(s) and song(s) in the output. For this assignment, assume that the user will always enter a valid integer value that is >= 0, and within the limit of the integer range. Here is an example of how your program should behave (the value (shown in bolded italic for clarification purpose only) is entered by the…arrow_forward
- using Visual Basic or VB.netarrow_forwardYou have been hired by a local smoothie shop to a program that will calculate the cost of a smoothie order. The shop sells four types of smoothies in three different sizes: Small (20 oz), Medium (32 oz) and Large (40 oz). Your program should use a menu for the type of smoothie and a second menu for the smoothie size. Calculate the total cost of the order including tax and display a bill for the smoothie. See the Sample Output. The sales tax rate is 4.5%. Use named constants to hold the cost per ounce of each of the products and the sales tax rate. Use the constants in your calculations and wherever else they are appropriate in your program. Product Cost per Ounce Banana $0.62Strawberry $0.60 Mango $0.48 Blueberry $0.57 Project 3 is a continuation of Projects 1 and 2. You will modify your code from Project 2 to make the program modular for this part of…arrow_forwardWhich statement will display The price is 4.99 Assume a variable called price stores the value 4.99. A print(The price is 4.99) B print("The price is" , price) C print('The price is price') D print('The price is ' , Price)arrow_forward
- oe’s Pizza Palace needs a program to calculate the number of slices a pizza of any size can be divided into. The program should perform the following steps: Ask the user for the diameter of the pizza in inches. Calculate the number of slices that may be taken from a pizza of that size. Display a message telling the number of slices. To calculate the number of slices that may be taken from the pizza, you must know the following facts: Each slice should have an area of 14.125 inches To calculate the number of slices, simply divide the area of the pizza by 14.125. The area of the pizza is calculated with this formula: Area NOTE: π is 3.14159. The variable r is the radius of the pizza. Divide the diameter by 2 to get the radius.arrow_forwardPLEASE COMMENT CODE Write a Python program that does the following Asks the user to enter the order. If the order is greater than $1000, there is 17% discount, if the order is greater than $800 and less or equal to $1000, the discount is 13%, if the order is less or equal to $ 800 but greater than $ 500, the discount is 9%, otherwise the discount is 5%. The tax percent is 13%. The program calculates the total invoice of the customer after the appropriate discount and the tax amount are applied. The program prints out the customer name (entered by the user), the discounted amount, the tax amount and the total invoice. The program asks if the user wants to continue using the application with a new order (y/n). Sample run: Please, enter the name of the customer: John Smith Please, enter the total of your order: $1100 Customer name: John Smith The order amount: $1100 The discounted…arrow_forwardThe game should begin by randomly dealing 2 cards to the user's hand, and then calculate and display the total. Next the program should display a prompt, asking the user if he/she wants a Hit or to Stand. If the user selects to Hit the game should randomly deal a new card to the user's hand, and then calculate and display the new total. If the total is greater than 21, then the user Busts, the house wins, and a message indicating these results is displayed. If the total is less than 21, repeat the Hit/Stand Prompt to the user. Continue this process until the user elects to Stand or Busts. If the user selects to Stand, the game then randomly deals two cards to the house, and then calculates those total points. The dealer must continue to Hit as long as the total of the House had is under 17, display the results after each Hit The dealer must Stand once the House hand reaches 17 or higher. Once If the user has not already Busted, compare the User's Hand to the House Hand and determine…arrow_forward
arrow_back_ios
arrow_forward_ios
Recommended textbooks for you
- Database System ConceptsComputer ScienceISBN:9780078022159Author:Abraham Silberschatz Professor, Henry F. Korth, S. SudarshanPublisher:McGraw-Hill EducationStarting Out with Python (4th Edition)Computer ScienceISBN:9780134444321Author:Tony GaddisPublisher:PEARSONDigital Fundamentals (11th Edition)Computer ScienceISBN:9780132737968Author:Thomas L. FloydPublisher:PEARSON
- C How to Program (8th Edition)Computer ScienceISBN:9780133976892Author:Paul J. Deitel, Harvey DeitelPublisher:PEARSONDatabase Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781337627900Author:Carlos Coronel, Steven MorrisPublisher:Cengage LearningProgrammable Logic ControllersComputer ScienceISBN:9780073373843Author:Frank D. PetruzellaPublisher:McGraw-Hill Education
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education