Concept explainers
Carpet Size
You have been asked to create an application for a carpet sales and installation business. The application should allow the user to enter the length and width of a room and calculate the room’s area in square feet. The formula for this calculation is
In this exercise, you will gain practice using Steps 1 through 6 of the
- 1. Clearly define what the application is to do.
- 2. Visualize the application running on the computer and design its user interface.
- 3. Determine the controls needed.
- 4. Define the values of each control’s relevant properties.
- 5. Determine the event handlers and other code needed for each control.
- 6. Create a flowchart or pseudocode version of the code.
Step 1: Describe the following
characteristics of this application:
Purpose
Input
Process
Output
Step 2: Draw a sketch of the application’s form and place all the controls that are needed.
Step 3: Make a list of the controls you included in your sketch. List the control type and the name of each control.
Step 4: List the value of the Text property for each control, as needed. (Remember, some controls do not have a Text property.)
Step 5: List each method needed. Give the name of each method and describe what each method does.
Step 6: For each method you listed in Step 5, draw a flowchart or write pseudocode.
Want to see the full answer?
Check out a sample textbook solutionChapter 1 Solutions
Pearson eText for Starting Out With Visual Basic -- Instant Access (Pearson+)
Additional Engineering Textbook Solutions
Differential Equations: Computing and Modeling (5th Edition), Edwards, Penney & Calvis
Java How to Program, Early Objects (11th Edition) (Deitel: How to Program)
Introduction to Programming Using Visual Basic (10th Edition)
Concepts of Programming Languages (11th Edition)
Database Concepts (7th Edition)
Objects First with Java: A Practical Introduction Using BlueJ (6th Edition)
- Using C# in Microsoft Visual Studio create an application that lets the user play the game of Rock, Paper, Scissors against the computer. The program should work as follows:1. When the program begins, a random number in the range of 1 through 3 is generated. If the number is 1, then the computer has chosen rock. If the number is2, then the computer has chosen paper. If the number is 3, then the computer has chosen scissors. (Do not display the computer’s choice yet.)2. The user selects his or her choice of rock, paper, or scissors. To get this input you can use Button controls, or clickable PictureBox controls displaying some of the artwork that you will find in the student sample files.3. The computer’s choice is displayed.4. A winner is selected according to the following rules:• If one player chooses rock and the other player chooses scissors, then rock wins. (Rock smashes scissors.)• If one player chooses scissors and the other player chooses paper, then scissors wins. (Scissors…arrow_forwardPlease provide answer in C#: Slot Machine Simulation A slot machine is a gambling device into which the user inserts money and then pulls a lever (or presses a button). The slot machine then displays a set of random images. If two or more of the images match, the user wins an amount of money that the slot machine dispenses back to the user. Create an application that simulates a slot machine. Figure 8-23 (on page 539 of your book) shows an example of how the form should look. The application should let the user enter into a TextBox the amount of money he or she is inserting into the machine. When the user clicks the Spin button, the application should display three randomly selected symbols. (Slot machines traditionally display fruit symbols. You will find a set of fruit symbols attached to this dropbox for your use - from the Student Sample Programs provided by the book author.) If none of the randomly displayed images match, the program should inform the user that he or she has won…arrow_forwardplz write it pseudocodearrow_forward
- Javaarrow_forwardi uploaded the screenshot please help me to do program source code.arrow_forwardPrograming language is C# 6. Hospital Charges Create an application that calculates the total cost of a hospital stay. The daily base charge is $350. The hospital also charges for medication, surgical fees, lab fees, and physical rehab. The application should accept the following input: • The number of days spent in the hospital • The amount of medication charges • The amount of surgical charges • The amount of lab fees • The amount of physical rehabilitation charges Create and use the following value-returning methods in the application: • CalcStayCharges—Calculates and returns the base charges for the hospital stay. This is computed as $350 times the number of days in the hospital. • CalcMiscCharges—Calculates and returns the total of the medication, surgical, lab, and physical rehabilitation charges. • CalcTotalCharges—Calculates and returns the total charges.arrow_forward
- PYTHON CODE Reza Enterprises sells tickets for buses, tours, and other travel services. Because Reza frequently mistypes long ticket numbers, Reza Enterprises has asked his students to write an application that shows if a ticket is invalid. Your application/program tells the ticket agent to enter a six-digit ticket number. Ticket numbers are designed so that if you lose the last digit of the number, then divide by 7, the remainder of the division is exactly the same to the last dropped digit. This process is shown below: Step 1: Enter the ticket number; for example 123454 Step 2: Remove the last digit, leaving 12345 Step 3: Determine the remainder when the ticket number from step 2 is divided by 7. In this case, 12345 divided by 7 leaves a remainder of 4. Step 4: Display a message to the ticket agent indicating whether the ticket number is valid or not. If the ticket number is valid, save the number to a .txt file called “tickets.txt” and continue to loop your program asking…arrow_forwardPython programming language You will be creating an application to calculate the maximum amount of contribution a person can make to a Roth IRA based on their age and income. Over 50 years old and your contribution limit goes up from $6000 to $7000 dollars. However, if the person is married and the combined household income is over $206,000 a year, or a single person with income over $139,000, you are not allowed to contribute. Write an application that asks the user their age and their income. Using this information use a nested if statement to calculate the maximum allowable contribution.arrow_forwardUs------c. Prak 9 Instructions PDF -mming Prak 9 Chapter 6: Modularizing Your Code with Methods 1. Salesperson's Commission Calculator (Nr 1, Page 408) Create an application that lets the user enter a salesperson's revenue sale and the rate of commission paid by the company, and display the commission earned. For example: • If a salesperson sells $100,000 in revenue while working with a company that pays 5 percent of the revenue, his/her commission check will be $5,000. • if a salesperson sells $100,000 in revenue while working with a company that pays 8 percent of the revenuo, his/her commission check will be $8,000. The program should have a method named CalculateDisplayCommission that receives the revenue sale by a salesperson and the commission percentage as arguments, and calculates and displays the commission earned by the salesman. See examples below: Salesperson's Commis. |Salesperson's Commis. 100000 Revenue Sale: 100000 Revenue Sale: Commission Percentage: Commission…arrow_forward
- Restaurant: Point-of-Sales System Create a software application that can be used for a Restaurant using C language. The expected minimum functionality are as follows: Menu Display It must display at least 10 choices with their corresponding prices On your menu, at least one of the categories/choice should have customization/add-on. You should have at least 3 customization/add-on (e.g. In Starbucks, you can have extra espresso shot). Taking Orders As a customer, I want to select which of the choices I want to order As a customer, everytime I specify select my choice, I want to specify the quantity of my selected choice. After I finished my order, it should ask, "Anything Else?". Afterwards, as a customer, I should be to enter my succeeding choice. In order to stop taking order, the exit should be part of the menu. As a customer, I would only select that choice to exit If the customer selects a choice qualified for customization, after specifying the quantity, I should be asked,…arrow_forwardA painting company has determined that for every 115 square feet of wall space, 1 gallon of paint and 8 hours of labor will be required. The company charges $20.00 per hour for labor. Create an application that allows the user to enter the square feet of wall space to be painted and the price of the paint per gallon. The program should display the following data:• The number of gallons of paint required• The hours of labor required• The cost of the paint• The labor charges• The total cost of the paint jobarrow_forwardPaint Job Estimator A painting company has determined that for every 115 square feet of wall space, 1 gallon of paint and 8 hours of labor will be required. The company charges $20.00 per hour for labor. Create an application that allows the user to enter the square feet of wall space to be painted and the price of the paint per gallon. The program should display the following data: • The number of gallons of paint required • The hours of labor required • The cost of the paint • The labor charges • The total cost of the paint jobarrow_forward
- Programming Logic & Design ComprehensiveComputer ScienceISBN:9781337669405Author:FARRELLPublisher:CengageEBK JAVA PROGRAMMINGComputer ScienceISBN:9781337671385Author:FARRELLPublisher:CENGAGE LEARNING - CONSIGNMENTProgramming with Microsoft Visual Basic 2017Computer ScienceISBN:9781337102124Author:Diane ZakPublisher:Cengage Learning
- C++ Programming: From Problem Analysis to Program...Computer ScienceISBN:9781337102087Author:D. S. MalikPublisher:Cengage LearningEBK JAVA PROGRAMMINGComputer ScienceISBN:9781305480537Author:FARRELLPublisher:CENGAGE LEARNING - CONSIGNMENT