Create a C++ program for an online shopping simulation with the following specifications: Define at least 4 categories of items (e.g., Electronics, Clothing, Books, Home Decor). For each category, provide a list of 3 items with associated prices. Prompt the user to select items by entering the corresponding item numbers and quantities. Calculate the total cost of the selected items. Apply a discount based on the following criteria: Total amount less than $75: No discount $75 to $149: 7% discount $150 to $249: 12% discount $250 or more: 18% discount Display the total cost, applied discount, and the final amount to be paid by the user. Please write a C++ program following the specified requirements, and include comments for clarity and self-documentation.
Q: wesome! the program is running perfectly! Lastly, instead of using a Hashmap, can this be done just…
A: SOLUTION -I have changed the code just using a LinkedList.In this code, we can use a single…
Q: Selectionsort takes time (rougly) proportional to n2 while mergesort takes time (roughly)…
A: Selection Sort is a straightforward sorting algorithm that splits the input list into the sorted and…
Q: Translate ER into Relations: ופן E isa G b R S f C 9 F H d h
A: In this question we are given with the ER diagram which is to be translated into relations.Let's…
Q: In a Java if-statement, a _________ goes in the blank in the following: If(_________)
A: The question is asking what goes in the blank of an if-statement in Java programming language.
Q: I submitted this answer before and the answer was wrong Hi, I'm struggling with 1.13 and could use…
A: We explored the design and behavior of a Deterministic Finite Automaton (DFA) that acknowledges…
Q: Python Given an array of integers and an integer target. Write a brute force algorithm that return…
A: Algorithm:1. Input: - accept the integer.2. Check Pairs: Iterate through each pair of elements…
Q: Convert total_dollars to 50-dollar bills, 5-dollar bills, and one-dollar bills, finding the maximum…
A: The following algorithm can be used to get the largest number of 50-dollar, 5-dollar, and one-dollar…
Q: Part 1 (5): Start by creating a new class called MyPoint that can be initialized with either of…
A: Class Definition:The class MyPoint encapsulates the properties and behaviors of a point, such as its…
Q: Sites like Zillow get input about house prices from a database and provide nice summaries for…
A: SOLUTION-I have solved this problem in Java code with comments and screenshots for easy…
Q: Explain the main features of any three multithreading models.
A: Multithreading is a programming and execution model that allows multiple threads to exist within the…
Q: Discuss the importance of data cleansing. What are pros and cons of data cleansing?
A: Introduce Data Cleansing:Data cleansing, also known as data cleaning or data scrubbing, is a crucial…
Q: What is the purpose of surveillance? What types and levels of surveillance are there? As it relates…
A: Public safety, crime prevention, and national security are all served by surveillance. Surveillance…
Q: what are those elements that need to be in place before running the installation?
A: Before starting the installation process, it is important to ensure that certain elements are in…
Q: Help me write code for the scale down function please, make sure the size of the block can't become…
A: Algorithm scaleDown(): 1. If the current size (this.size) is greater than 2: 2. Calculate the…
Q: Use the definitions for A, B, C, D, and E to answer the question: Do the sets A, B, and C form a…
A: The question is asking whether the sets A, B, and C form a partition of the set of all real numbers…
Q: Explain how the Data Science Methodology (DSM) is adaptive and its Advantages?
A: The Data Science Methodology (DSM) is a systematic and iterative approach to solving complex…
Q: In a physical network diagram, which of the following entities should be documented? [Choose all…
A: An illustration of the physical configuration and connections between networking hardware,…
Q: An all-NFA M is a 5-tuple (Q, E, 6, qo, F) that accepts x € Σ* if every possible state that M could…
A: We provide two formal definitions for all-NFAs: one with ε-transitions (like the NFA in class) and…
Q: The volume of liquid, V, in a partially filled, horizontal, cylindrical tank of radius r and length…
A: Step-1) importing the numpy as np and matplotlib.pyplot as plt for plotting the graph.Step-2) Next,…
Q: Which states are in the g-closure of {q0, q2}? الله 90 q1 92 95 X م 93
A: We are given to find e-closure of {q0, q2}We are supposed to find e-transition for either q0 or q2…
Q: I need to plot the vector r(t)=tsin(t)î+(2+tcos(t))j with 0 <= t <= 6pi and assign the plot to q.…
A: in this question you have given matlab code and asked to find error. in the following steps you will…
Q: Examine the concept of client server architecture
A: Client-server architecture is a computing model where tasks or processes are divided between clients…
Q: How many elements are there in the set A3, where A = {0, 1}.
A: The question is asking for the number of elements in the set A^3, where A is a set containing two…
Q: How would I do this on Jupyter using the functions len() and print()? Write a program that asks user…
A: I have provided PYTHON CODE along with CODE SCREENSHOT and OUTPUT SCREENSHOT...Note: Copy and paste…
Q: where is the remove function?
A: consolidate(Block block):Purpose: This method integrates a block into the board once it stops…
Q: Let 1 represent true and 0 represent false. The function Conjunction(), whose incomplete code is…
A: The objective of the question is to complete the function Conjunction(p, q) which computes the…
Q: How would you modify Strassen’s algorithm to multiply n×n matrices in which n is not an exact power…
A: Matrix multiplication is a fundamental operation in various computational tasks, and Strassen's…
Q: What is the equivalent regular grammar for the following context free grammar?. O A. SaS | bS | A;…
A: Given grammar is:The variables present in the grammar are S, A, B and the non terminals present in…
Q: In Java programming, when is it appropriate to use user-defined exceptions vs. built-in exceptions?
A: The objective of the question is to understand when to use user-defined exceptions and when to use…
Q: To increment a variable x in Java, we code the following: x=x+1; x++; x+=1; All of the above are…
A: All three options achieve the same result and are correct ways to increment the value of a variable…
Q: (a) Compute V178212+184112 by typing the following into MATLAB: format short (1782 12+ 1841-12)…
A: a) computing the (1782 ^ 12 + 1841 ^ 12) ^(1/12) formal using matlab and anwsering using long. (b)…
Q: Hello, I'm having difficulty with part H of question 1.7 and could use some help. The challenge…
A: A computer science theoretical model known as a Non-deterministic Finite Automaton (NFA) is used to…
Q: Do the Memory allocation for the given case using the Buddy System A 1024 Kbyte (Mbyte) block of…
A: Memory allocation is a crucial aspect of computer systems, involving the assignment of portions of…
Q: Varian and Mateo are alchemists trying to outdo each other. Varian has created a magical device that…
A: A world where alchemical gadgets can turn lead into gold is the setting for Varian and Mateo's…
Q: In Matlab. Analyze the rabbit growth rate problem using the transform Z. The following reference is…
A: The rabbit growth rate problem typically refers to a mathematical or computational model used to…
Q: Both while loops and do-while loops are executed as long as a stated boolean condition is true and…
A: While loop:first verifies the condition: it assesses the boolean condition prior to carrying out any…
Q: a progra sphere nion, an online fashion ne store offers three flagship products: TrendBlaze Jacket,…
A: Define a class for fashion products with attributes like name, details, sizes, price, and special…
Q: I am creating a lottery program. That generates three random numbers, each between 0 and 9. Allow…
A: Python is a high-level, interpreted programming language that has gained popularity due to its…
Q: a) For the first image (pentagon graph) can you show how the graphs are isomorphic aand also label…
A: This question comes from graph theory which is a topic discrete mathematics a paper from computer…
Q: Examine the concept of unit testing.
A: Unit testing is a software testing methodology where individual units or components of a software…
Q: What are the primary components and considerations involved in requirement gathering during the…
A: Requirements Identification or Requirement gathering is a very important stage in the process of…
Q: Write components of a data communication system.
A: A data communication system is a network of interconnected components designed to transmit, receive,…
Q: Using the table owner_spend_date, write a query that returns a count of distinct owners and their…
A: The provided SQL statements define the structure of a table named owner_spend_date to store owner…
Q: A valid argument is given below. Fill in the missing values of the proof. Vx(P(x)→ Q(x)) 3x…
A: Here, a proof applying the predicate logic is given. The task is to fill the missing values to the…
Q: In the simplified English grammar of the given Figure, there are only finitely many legal sentences.…
A: The objective of the question is to determine the total number of legal sentences that can be formed…
Q: Examine the concept of unit testing.
A: Unit testing is a foundational practice in software engineering that focuses on validating the…
Q: The university has decided that they need to do a better job of keeping track of all of the…
A: We define a structure Student to hold the required information about a student.In the main function,…
Q: Describe the network environment? And describe spectrum network environment.
A: In this question we have to descibe the network environment and spectrum network environment.Network…
Q: Write a function binary search (mylist, myvalue) that im- plements the recursive binary search…
A: The function binarysearch takes a sorted list of numbers mylist and a target value myvalue as input…
Q: I need help on this?
A: The objective of the question is to create a program that analyzes the words played by professional…
Step by step
Solved in 4 steps with 4 images
- 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…The Westfield Carpet Company has asked you to write an application that calculates theprice of carpeting for rectangular rooms. To calculate the price, you multiply the area of thefloor (width times length) by the price per square foot of carpet. For example, the area offloor that is 12 feet long and 10 feet wide is 120 square feet. To cover that floor with carpetthat costs $8 per square foot would cost $960. (12 3 10 3 8 5 960.)First, you should create a class named RoomDimension that has two fields: one for the lengthof the room and one for the width. The RoomDimension class should have a method thatreturns the area of the room. (The area of the room is the room’s length multiplied by theroom’s width.)Next you should create a RoomCarpet class that has a RoomDimension object as a field. Itshould also have a field for the cost of the carpet per square foot. The RoomCarpet classshould have a method that returns the total cost of the carpet.Figure 8-21 is a UML diagram that shows…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…
- For each of the following exercises, you may choose to write a console-based or GUI application, or both. Write a program for The Carefree Resort named ResortPrices that prompts the user to enter the number of days for a resort stay. Then display the price per night and the total price. Nightly rates are $200 for one or two nights; $180 for three or four nights; $160 for five, six, or seven nights; and $145 for eight nights or more.Description: The program starts by asking the user to select either login (L) or sign up (S) feature. Once the user selects a feature, it asks him for (Card Number, then PIN) and after filling the required information for that feature, it shows the above menu for other features. Otherwise, it keeps asking for the required information. Each feature has to be designed using a separate function and it might be called by other functions including the main function. The description of the login feature, sign up feature, and the above features are given below: Sign up Feature – def create(): this feature allows new user to create an account and it saves his information in txt. The required information to be asked in this feature as follows: Card Number: user will enter a card number and should be four digits, each digit is unique and it should not be repeated in the 4-digits card number. This feature will keep running until the user enters the required number with same length and…Java Programming A bakery company provides a bonus of a new bakery product package for customers who buy at least 10 breads in the company anniversary award which will be celebrated in the next three months. To get the bonus, the customer is given the opportunity three times to guess a number determined by the application from numbers 1 to 20. For each guess number given by the customer, the application will respond as follows:• If the guessed number is smaller than the lucky number, you will see the words "Bigger Number"• If the guessed number is greater than the lucky number, you will see the words "Smaller Number"• If the guessed number is the same as a lucky number, it will match the words "Congratulations ... you found a LUCKY number"As part of the company's IT team, you serve to create a lucky number guessing game console.A. Determine the inputs and outputs of the design programb. Draw a Flowchart of the programc. Write Coding to make the applicationd. Give Screen shoot the…
- Please 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…uppose you have a certain amount of money in a savings account that earns compoundmonthly interest, and you want to calculate the amount that you will have after a specificnumber of months. The formula, which is known as the future value formula, is:F=P×(1+i)tThe terms in the formula are as follows:o F is the future value of the account after the specified time period.o P is the present value of the account.o i is the monthly interest rate.o t is the number of months.Write a program that prompts the user to enter the account’s present value, monthlyinterest rate, and the number of months that the money will be left in the account. Theprogram should pass these values to a function named futureValue that returns thefuture value of the account, after the specified number of months. The program shoulddisplay the account’s future value. i attached the screenshot of the output so the output should look like that. the coding should be in c++T=63, n=12 and A=(3,5,8,8,9,16,29,41,50,63,64,67). Draw the corresponding walkthrough as shown
- Build a calculator program that can allow user to select the specific arithmetic operation from the menus provided by the program. Initially, this program will displays a main menu to choose the calculator type. If a user chooses Standard calculator, then a menu appears for standard calculator option. If the user chooses Scientific calculator, then menu appears for scientific calculator options and the last option to Quit/Continue from the program. In standard calculator, users are able to select the option for addition, subtraction, multiplication and division process, whereas in scientific calculator, the options are power, factorial, square root YOUR TASK Your team is required to design and develop a program using C++ language and apply modular programming concept. Your C++ program should capable to perform the following tasks:In python Expense tracker: the user should be able to enter expenses per category (food, clothing, entertainment, rent, etc) and the application should track the expenses per week or month. The user should be able to see their total expenses for a month of their choice for each category and a total monthly expense. The monthly expense report should include average expenses for each category for the year and indicate if the user expense for the month selected is lower or higher than the annual average. Also, the report should display the percentage of expenses from each category out of the total monthly expenses. Project application requirements: Requirements description Basic Points: * Project should have a functioning menu * Project should have adequate functions (minimum 3 functions) * Project should make use of files to save the data * Project should handle adequate exceptions * Project should display information formatted adequately * Project should make use of lists or…Create a modularized Rock, Paper, and Scissors game that lets user play 7 Rock, Paper, and Scissors game against computer. The program should display each game's result and the final result for the 7 games. The program should contain the following procedures: getComputerChoice receives nothing but returns a word randomly picked from Rock, Paper, and Scissors. getUserChoice receives nothing but returns a word user picked from Rock, Paper, and Scissors. play receives computerPicked and userPicked and returns winner's name, computer or user. main: call the above procedures 7 times, display each game's result, and final result summary any way i can get help creating this in raptor flowchart?