Write a program that reads from the user the cinema ticket price and the number of history cinema reservations of a customer. The program then prints the discount amount and discounted ticket price based on the number of reservations. Discount = ticket price discount rate /100 final price ticket price- Discount Number of Reservations discount rate <5 5-10 Using java 10% >10 25% Sample Run 1: Enter the ticket price and number of history reservations: 15000 3 Discount Amount is: 0.0 Final price is: LL 15000.0 Sample Run 2: Enter the ticket price and number of history reservations: 15000 6 Discount Amount is: 1500.0 Final price is: LL 13500.0 Sample Run 3: Enter the ticket price and number of history reservations: 15000 11 Discount Amount is: 3750.0 Final price is: LL 11250.0
Q: What are the tools and technologies can make database more accessible and useful.
A: The solution to the given question is: There is a wide variety of database tools and techniques are…
Q: If there are page defects 99 percent of the time, then this indicates that they occur often (that…
A: Introduction: Translation Lookaside Buffer, sometimes known as TLB, is a paging solution that aims…
Q: Based on the information in the graph, to design a network addressing scheme to supply the minimum…
A: Given network contains a router and three subnets. The IP address of the network is 135.126.0.0. The…
Q: a Gantt chart of the process scheduling using preemptive, priority-based scheduling. Determine the…
A:
Q: A Full Adder Circuit is shown in Figure utilizing two Half Adders and an OR Gate. The major input…
A:
Q: Using MATLAB draw the equation: U(theta)=cos(2theta) cos(3theta)
A: The following step provides the solution in MATLAB to plot a graph for the given equation…
Q: Write a C++ program to generate and print the following figure 12345 2345 345 45
A: Answer the above program are as follows:
Q: Q37 b/ Write a program in C++ to generate and print the following form: I 2 3 4 5 234 5 345 4 5
A: C++ program to generate a program in C++ to generate and print the pattern: 123452345345455…
Q: The default appearance of the Desktop in MATLAB three windows * :will appear. They are Current…
A: The three windows are Current Directory, Command Window, and Workspace.
Q: Write a program that shows that the square of the normal is χ2
A: Given To know about the programming and program of square of number.
Q: 2. For the BinaryNode class a. Make all attributes private b. Write code for a default no-argument…
A: Here I have created the class BinaryNode. In this, I have created private data members. Next, I have…
Q: Is the usage of the QR Code system detrimental to the provision of library services, and if so, in…
A: One such innovation is the Quick Response (QR) code, which may consider the client's desire to get…
Q: What are the technical feasibility for the project analysis?
A: A technical feasibility study assesses the details of how you intend to deliver a product or service…
Q: What is the Classic CPU Performance Equation and how does it work?
A: Introduction: Computer programs are executed by a central processing unit (CPU), sometimes known as…
Q: Q6) Compare and contrast SRAM with DRAM.
A: As per company guidelines we are suppose to answer only 1 question. Kindly re-post other questions…
Q: 1/ Write a program in C++ to find and print the sum of the following series for n terms
A: In this question, there is series given and we have to find out
Q: How would you answer these questions? When it comes to data backup and restoration, what are the…
A: Backup of data: Data backup is the process of duplicating data that enables us to retrieve our data…
Q: Given the interface of the Linked-List struct Node{ int data; Node* next = nullptr; };…
A: We need to write a definition for a method display_at, that takes as a parameter integer that…
Q: In terms of information security, what's the difference between a top-down and a bottom-up approach?…
A: Approach from the top down: The top-down technique divides a system into subsystems to properly…
Q: Are there any network topologies that can be implemented, and which do you prefer?
A: Introduction: A Mesh Topology network has the greatest links, making it the most practical…
Q: Is it possible to identify and address the weaknesses of the Whetstone, Dhrystone, and Linpack…
A: SPEC CPU Benchmarks In order to set a standard that would aspire to guarantee reliability in the…
Q: What effect did John von Neumann's educational background have on his subsequent mathematical…
A: Introduction: The concept of a mathematical profession has expanded and varied, and it is often…
Q: Who was the individual who was responsible for the invention of the motherboard?
A: Introduction: A motherboard is a piece of computer hardware used in personal computers that houses…
Q: Write a program that reads from the user the initial KiloMeters of the car, the current KiloMeters,…
A: Note: as programming language is not mentioned c++ is used. The program with output is given below
Q: could anyone help me with putting in an infinite loop of platforms that go upwards in difderent…
A: Lua is an open source programming language based on the C computer language. It has a wide range of…
Q: Please help me create a program that takes the input of the stock, views stock, dispatch stocks, and…
A: RAPTOR is a problem-solving tool that uses a flowchart-based programming environment. we draw a…
Q: Several editing and rewriting techniques were discussed in this course. What is your most often used…
A: Characteristics of revision and editing: The two most critical aspects of the writing process are…
Q: Create a C++ program code using the given flowchart in Visual Studio Code app.
A: I have prepared the code for you as follows: Please Appreciate and upvote, thank you. Code: #include…
Q: From 2/ b/write a program in C++ language, to calculate the income tax for a person whose daily…
A: The program is written in C++. Check the program screenshot for the correct indentation. Please…
Q: computer Are you familiar with Ada Lovelace's ideas?
A: Introduction: She not only helped to establish computer science as a subject, but she also launched…
Q: When hashtags appear in an Excel column, what does it mean?
A: The Answer is given below step.
Q: Write a function that accepts the length and width of a rectangle as it's only arguments. The…
A: In this question we have to program a function for calculating area and perimeter of the rectangle.…
Q: A person's physical and cultural development is influenced by how they learn.
A: The answer is as follows.
Q: Discuss the benefits and drawbacks of moving to an enterprise-level analytics solution for…
A: Benefits and drawbacks of moving to an enterprise-level analytics solution for enterprises and end…
Q: Why is it so important to secure online applications? What could possibly go wrong with an…
A: Securing web applications Web application security testing verifies that the information system is…
Q: What is the byte equivalent of a gigabyte in terms of storage capacity?
A: What is the byte equivalent of a gigabyte in terms of storage capacity?
Q: The right time to put a brouter on your network depends on your situation.
A: Introduction: A router is a term that combines the phrases bridge and router. Brouwer makes…
Q: Can someone show a polynomial time reduction from CNF-SAT to Dominating set with images? thanks
A: Can someone show a polynomial time reduction from CNF-SAT to Dominating set with images.
Q: If you want to know how computers were obtained, utilised, and accounted for, explain the procedures…
A: The Answer is in step-2.
Q: When it comes to keeping track of this data, why is Access better than Excel?
A: When it comes to keeping track of this data, why is Access better than Excel?
Q: Briefly explain 4 enterprise system data and how they apply to an organisation
A: Enterprise information is the entirety of the advanced data moving through an association. This…
Q: Write code (python) to generate and display an image like this. Be sure to get the location of the…
A: image : ndarray Input image data. Will be converted to float. mode : str One of the…
Q: USE PYTHON LANGUAGE. READ INPUT FROM FILE (NAME THE FILE "input.txt') The problem needs to be…
A: Answer
Q: Is it feasible to learn where John von Neumann went to primary school and what grade he attended?
A: Yes it is feasible to know where the John von Neumann went to primary school and what he studied.
Q: Explain how SETI Institute computers work together to create an even more powerful system.
A: Introduction: SETI (Search for Extraterrestrial Intelligence) is an abbreviation that stands for the…
Q: Which Macintosh machine was the first to be manufactured?
A: Introduction: The Macintosh (often referred to as "the Mac") was the first widely distributed…
Q: Do you know how old the original USB flash drive was?
A: Solution: Given, Do you know how old the original USB flash drive was?
Q: What mathematical contributions did Charles Babbage make?
A: Introduction: The Institution of Cambridge was founded in 1209 and is the second oldest university…
Q: What kind of memory is being utilised for the primary storage?
A: - We need to talk about the type of memory utilised for primary storage.
Q: Q3/ b/ Write a program in C++ to
A: the c++ code with output snapshot is given below
Step by step
Solved in 4 steps with 5 images
- Question Using Java programming language write a program to manage a hotel with 24 rooms;10 rooms are Executive, with price Gh ₵ 2500.00 per night,7 rooms are Chalets, with amounts Gh ₵ 1500.00 per night7 rooms are Ordinary, with amount Gh ₵ 500.00 per night The program should allow customers to book for rooms for a number of nights, and update the number of empty rooms available for each category when a customer has paid fully and has checked-in; also update the number of empty rooms available when customer checks-out.Customers should make bookings with their first names, telephone number A customer should be prompted to know if a room is booked (meaning a another customer has booked it but has not paid fully, or has not checked-in) A customer should be prompted to know if a room is occupied (meaning a booked room has been fully paid for, or the customer has checked-in) A customer should be prompted to know if a room is available (meaning a room has neither been booked nor…Problem: An online grocery store sells items on a web page. A user adds items to a basket and he clicks on the submit button when he completes. The store sells food and electronic items. The electronic items require VAT payment of 15 percentage of their prices. There are packed and lose food. The lose food is measured in weights. User specifies the weight amount or the quantity in his selection of items depending on its type. The price is computed as the product of the price per item or the price per weight and the weight or quantity are given by the user. Write an application that reads a user basket list and produces the bill receipt. Check the given samples of input/output in the figures below. The bill receipt contains the list of item details in decreasing order according to the price computed for each item. Use the selection sort' to sort the items in the list and do not use java given sort method. Selection sort is an algorithm used to arrange elements in a list. It selects the…JAVA PROGRAMMING LAB Write a Java program to takes 2 numbers from the user and print true if one or the other is teen, but not both. "teen" number is that number which lies in the range 13..19 inclusive.
- Computer Science Write a Java program that calls a method from main and passes it two integer parameters called minValue and maxValue. The method should prompt the user to enter a number within the range of minValue and maxValue (inclusive), until the user provides a valid input. The method should return the value provided by the user, and the program should display what the user entered after the method is called.Java Your program will read in a credit card number and expiration date from the user and validate the data. The program will continue to ask for user input until a valid number and date are entered. The rules for what is valid are specified below. readYear() and readMonth(int) methods Complete the readYear() and readMonth(int) methods. These methods ask the user to input the expiration year and month of their credit card. Each method should contain a loop inside the method so the code repeats until a valid month or year is entered by the user. If the user enters an invalid year or month, print an error message and ask them to try again. The readMonth(int) method reads in the month as a number. A valid month is any number between 1 and 12 (inclusive). A valid year is 2022 or later. readCreditCardNumber() method Complete the readCreditCardNumber() method. This method asks the user to input their credit card number. This method should contain a loop so the code repeats until a valid…Assignment Write a program that moves a forester unit and a desert corps unit to a given target location and prints the number of hours it took for each unit to reach the target. First, the user will give the starting X and Y positions of the forester unit as well as its base speed (all ints). Then, the starting X and Y positions of the desert corps unit as well as its base speed (all ints). Finally, the target X and Y positions (both ints) and the terrain type (std::string). Speeds are given as distance traveled in one full day (i.e., 24 hours) and is affected by the terrain type using a multiplier over the base speed. Also, after 1 full day, each unit rests for a certain number of hours. Speed multiplier and rest amount of each type of unit depending on the terrain type are as below. Speed Multiplier Rest Duration After 1 day Terrain type Forester Desert Corps Forester Desert Corps Forest 1.3 0.6 4 12 Desert 0.4 1.2 15 6 Hills 0.7 0.8 6 8 Others 1.0 0.8 8 6 After getting all this…
- in Java Tasks Write a program 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 is 2, then the computer has chosen paper. If the number is 3, then the computer has chosen scissors. (Don't display the computer's choice yet.) 2. The user enters his or her choice of "rock", "paper", or "scissors" at the keyboard. (You can use a menu if you prefer.) 3. The computer's choice is displayed. Tasks 4. A winner is selected according to the following rules: a. If one player chooses rock and the other player chooses scissors, then rock wins. (The rock smashes the scissors.) b. If one player chooses scissors and the other player chooses paper, then scissors wins. (Scissors cuts paper.) C. If one player chooses paper and the other player chooses rock, then paper wins. (Paper wraps…JAVA CODE Write a program that quizzes the user on the names of the capital cities for all the states in the United States. Each state is presented to the user, and they must enter the name of the capital. The program then either tells the user they're correct or tells them the correct answer. The user's answer should not be case-sensitive. At the end, the program tells the user the total number they got correct. Here's an example: What is the capital of Alabama? Montogomery The correct answer is Montgomery. What is the capital of Alaska? juneau That is the correct answer! ... You got 32 out of 50 correct! The state capitals will be stored in a 2D String array of size 2 x 50, with the first column the name of the state and the second the name of the capital city, for all 50 states. To create the state capitals array, follow these instructions: Copy the String from the attached file into your program (found below these instructions). The String is a pipe delimited list of states and…In C++ language, create a program that gets quarterly sales from a user, and calculates the total of all four quarters as well as the average, lowest, and highest quarters. Console Example The Quarterly Sales program Enter sales for Q1: 12312.57 Enter sales for Q2: 15293.21 Enter sales for Q3: 14920.95 Enter sales for Q4: 23432.21 Total: 65958.94 Average Quarter: 16489.74 Lowest Quarter: 12312.57 Highest Quarter: 23432.21 Specifications: Create the pseudocode needed to implement the solution above. Convert your pseudocode to C++ code including the following specifications: Round the average quarter to a maximum of 2 decimal digits. Use a vector to store the sales for each quarter. Use STL algorithms to process the data for the quarters.
- JAVA PROGRAM Chapter 5. PC #2. Retail Price Calculator (page 312) Write a program that asks the user to enter an item’s wholesale cost and its markup percentage. It should then display the item’s retail price. For example: • If an item’s wholesale cost is 5.00 and its markup percentage is 100 percent, then the item’s retail price is 10.00. • If an item’s wholesale cost is 5.00 and its markup percentage is 50 percent, then the item’s retail price is 7.50. The program should have a method named calculateRetail that receives the wholesale cost and the markup percentage as arguments, and returns the retail price of the item. Class name: RetailPriceCalculator PLEASE MODIFY THIS JAVA PROGRAM SO WHEN I UPLOAD IT TO HYPERGRADE IT PASSES ALL TEST CASSES PLEASE. RIGHT NOW IT SAYS 0 OUT 5 PASSED. THE PROGRAM IS NOT WORKING IN HYPERGRADE FIX IT SO IT WILL WORK IN HYPERGRADE. THANK YOU. import java.util.Scanner;public class Main { public static double calculateRetail(double…Java Program Chapter 5. PC #2. Retail Price Calculator (page 312) Write a program that asks the user to enter an item’s wholesale cost and its markup percentage. It should then display the item’s retail price. For example: • If an item’s wholesale cost is 5.00 and its markup percentage is 100 percent, then the item’s retail price is 10.00. • If an item’s wholesale cost is 5.00 and its markup percentage is 50 percent, then the item’s retail price is 7.50. The program should have a method named calculateRetail that receives the wholesale cost and the markup percentage as arguments, and returns the retail price of the item. Class name: RetailPriceCalculatorJAVA PROGRAM Chapter 5. PC #2. Retail Price Calculator (page 312) Write a program that asks the user to enter an item’s wholesale cost and its markup percentage. It should then display the item’s retail price. For example: • If an item’s wholesale cost is 5.00 and its markup percentage is 100 percent, then the item’s retail price is 10.00. • If an item’s wholesale cost is 5.00 and its markup percentage is 50 percent, then the item’s retail price is 7.50. The program should have a method named calculateRetail that receives the wholesale cost and the markup percentage as arguments, and returns the retail price of the item. Class name: RetailPriceCalculator PLEASE FIX AND MODIFY THIS JAVA PROGRAM SO WHEN I UPLOAD IT TO HYPERGRADE IT PASSES ALL TEST CASSES PLEASE. RIGHT NOW IT SAYS 0 OUT 5 PASSED. THE PROGRAM IS NOT WORKING IN HYPERGRADE FIX IT SO IT WILL WORK IN HYPERGRADE. THANK YOU. import java.util.Scanner;public class Main { public static double…