Consider the following code segment. It should display a message only if the cost is between 50 and 75 dollars. The message should also be displayed if the cost is exactly 50 dollars or exactly 75 dollars. if ..... print ("The cost is in the desired range") What condition should be placed in the blank to achieve the desired behavior? Select one: coat >= 50 or con t = 75 DOat > 50 coat >= 50 and cost 75 cost 73
Q: Assignment 8.1b- Evaluate the following expressions. Assume that the value of x = 25, y = 10, z =…
A:
Q: A company manufactures three products engines, pumps and fans. They give a discount of 10% on orders…
A: I have provided C++ CODE along with CODE SCREENSHOT and also provided OUTPUT…
Q: A certain store has the following scheme: Commodity Code: J- commodities are discounted by 8% K-…
A:
Q: A certain store has the following scheme: Commodity Code: J- commodities are discounted by 8% K-…
A:
Q: Suppose p: 'You get a speeding ticket' and q: 'Your insurance rate goes up.' Select the correct…
A: p: 'You get a speeding ticket' q: 'Your insurance rate goes up.' 'If your insurance rate doesn't…
Q: A BOOKSTORE SELLS BOOKS UNDER THE FOLLOWING CONDITIONS: a. IF THE CLIENT IS TYPE 1, 30% IS…
A: Program: //header file #include <iostream> using namespace std; //main function int main()…
Q: In college, a student may get a grade of 1.0 (as the highest) to 5.0 (lowest). Anyone who get's a…
A: 1) Below is C program to that ask the user to input midterm and tentative final grade, calculate…
Q: A customer want to buy five items. He has only 75.0 OMR with him. The price of the products are…
A: Define mouse←6.50, keyboard←10.50, webcam←15.00, flashDrive←5.25, headphone←7.50, pen←1.00 Define…
Q: Assume that variable num is an integer variable which is assigned a random value from zero (0) to…
A: There can be many expressions that can be written inside the if bracket to validate the validate the…
Q: A customer want to buy 6 items. He has only 50.50 OMR with him. The price of the products are…
A: Algorithm: Start Declare and initialise variables…
Q: What would be displayed as the daily dosage of medicine to be administered to a dog weighing 1O…
A: The correct answer is given below with step by step explanation
Q: Question 2 The following board is used to create a simple floor pattern in a game. Each cell is…
A: Since no programming language is mentioned, I am using python. Algorithm: Start Read a letter 'n'…
Q: Write a program in C language using switch case statement to evaluate the following formulae and…
A: Given that write a C language using switch case statement to evaluate the following and print the…
Q: An Internet service provider has three different subscription packages for its customers: Package A:…
A: import java.util.*; public class InternetServiceProvider { public static void main(String[] args) {…
Q: C++ code that given a date (year, month and day) finds and displays the next date. Consider all the…
A: Below is the C++ program to find the next date of the entered date: - Explanation: - Importing the…
Q: code
A: Introduction Java is basically a type of programming language that is very much beneficial and can…
Q: 2. The following table contains earthquake magnitude ranges on the Richter scale and their…
A: C++ code for the above problem:- #include<iostream>using namespace std;int main(){float…
Q: UO wants a program that displays the amount of money charged for a seminar. The fee per person is…
A: // Code in java import java.util.*; public class Main{ public static void main(String[] args) {…
Q: A company has two categories of solar system installation, the small system and the large system.…
A: Find Your Code Below
Q: blä: 3 This code program enters the value of x then the value of y is computed from one of the…
A: Required : To select proper statement from the given options.
Q: Complete the flowgarithm/pseudo code for the following scenario and upload into drop box Program…
A: pseudo code is the steps required to solve a particular problem in informal language. It uses common…
Q: A Computer Science instructor at a computer school wants his students to create a program that…
A: #include<iostream> using namespace std; int main(){ double…
Q: Write a program that prompts a user for the number of eggs in the order and then display the amount…
A: Introduction of Program In the above Java Program PricePerEgg variable declared as the double and…
Q: c++ Energy Drink Consumption A soft drink company recently surveyed 16500 of its customers and…
A: #include<iostream> #include<cmath> using namespace std; int main()…
Q: GRADED ACTIVITY #5 (M7.2): DECISION CONTROL STRUCTURE (SWITCH) PROBLEM Instruction: The areas of the…
A: Find the required given as below and output:
Q: You are writing code which asks the user to input a number and prints "odd" if it is odd, and "even"…
A: You are writing code which asks the user to input a number and prints "odd" if it is odd, and "even"…
Q: You are required to draw flow chart and write a Pseudocode for the following problem statement.…
A: Pseudo code: 1) Take input all the five values: customer name, mobile model, visit date, total…
Q: Bank Utara Malaysia (BUM) has decided to give dividend to its account holders at the end of year…
A: begin input the account balance if account balance is less than equal to 10000 dividend = (account…
Q: 19. The sales manager at Memey Company wants to display a price based on a product ID she enters.…
A: Given: We are given a problem where we have product ID and their corresponding prices. Goal: We have…
Q: Visual Basic. Write the definition of a function named quadratic that receives three double…
A: Formula for quadratic equation:
Q: Text-based adventure game: Pretend you are creating a text-based adventure game. At different points…
A: def choice(c): if c == 1: print("Fight") elif c == 2: print("Run") elif c ==…
Q: Cashier 1.0 is a C++ program that displays on the screen "Sweet and minty Lollipops! How many would…
A:
Q: How do you write the income tax calculator in python
A: Algorithm: Start Read amount If amount is valid, print 0.04*amount Else print error message and…
Q: a) ¿Create a programming flowchart that requires computing the grade of a student through getting…
A: - The question is for a flowchart of the given marks average problem.
Q: Write a selection statements to to check whether the values of two variables i and j are divisible…
A: selection statement selects among a set of statements depending on the value of a controlling…
Q: A customer want to buy 6 items. He has only 50.50 OMR with him. The price of the products are…
A: Algorithm: Start Initialize amount to 50.50 OMR Initialize prices array with given prices…
Q: Python Programming. Write a program that computes how much a customer has to pay after purchasing…
A: According to the information given:- We have to follow the instruction mentioned to get the desired…
Q: The color of your eyes might reveal much more about your soul than you think. An eye color could be…
A: Algorithm: 1. Read name as name. 2. Read eye color as eyeColor. 3. IF eyeColor is 'B' or 'b' Then:…
Q: What would be displayed as the daily dosage of medicine to be administered to a dog weighing 4.9…
A: Given psudocode is if dogWeight numeric then number500 = dogWeight * 2 if number500 MOD 1…
Q: Ajax Manufacturing needs a program for employees to calculate gross pay themselves in order to have…
A: Working of the flowchart Prompt user to enter hours worked Read hours Prompt user to enter pay rate…
Q: Vrite a complete program that prompts the user to enter two integer numbers and y, and outputs the…
A: //Note no programming language is mentioned so I was used c++ programming language #include…
Q: Using logical operators and conditional statements, write a Visual Basic Code whereby if a student…
A: SOURCE CODE Module VBModule Sub Main() 'Declaring the local variables Dim score As Integer…
Q: 2. The following table contains earthquake magnitude ranges on the Richter scale and their…
A: The programming methodology is given by: Including header files Main function Declaring magnitude…
Q: KEMBOJA Hospital provides top-notched medical care with comfortable rooms. The following are the…
A: Note : as per company guidelines we are supposed to answer only first 3-sub parts . please repost…
Q: software company sells a package that retails for 599. Quantity discounts are given according to the…
A: According to the question we have to write C++ code for following question:
Q: amount of money charged for a seminar. The fee per person is based on the number of people…
A: Since no programming language is mentioned I am using c++ Algorithm: 1. Start 2. Enter the number of…
Q: When evenly divisible by 3, print “statement 1”. When evenly divisible by 8, print “statment 2”.…
A: Since no programming language is mentioned, I am using c++ Algorithm: Start Read a number If n%3==0…
Q: ENGE ACTIVITY 4.4.6: If-else expression: Operator chaining. Write an expression that will print…
A: Code: userinput = int(input())if(userinput>=9 and userinput<=12): print("in high…
Q: 3. Write a program named Admission for a college’s admissions office. The user enters a numeric high…
A: using System.IO; using System; class Program { static void Main() {…
Max Function
Statistical function is of many categories. One of them is a MAX function. The MAX function returns the largest value from the list of arguments passed to it. MAX function always ignores the empty cells when performing the calculation.
Power Function
A power function is a type of single-term function. Its definition states that it is a variable containing a base value raised to a constant value acting as an exponent. This variable may also have a coefficient. For instance, the area of a circle can be given as:
Trending now
This is a popular solution!
Step by step
Solved in 2 steps
- Write a program that calculates and displays a person’s body mass index (BMI). The BMI is often used to determine whether a person with a sedentary lifestyle is overweight or underweight for his or her height. A person’s BMI is calculated with the following formula:BMI = weight × 703 / height2where weight is measured in pounds and height is measured in inches. The program should display a message indicating whether the person has optimal weight, is underweight, or is overweight. A sedentary person’s weight is considered to be optimal if his or her BMI is between 18.5 and 25. If the BMI is less than 18.5, the person is considered to be underweight. If the BMI value is greater than 25, the person is considered to be overweight please write code on c++1- You are required to draw flow chart and write a Pseudocode for the following problem statement. Muscat MobiCare is a Mobile Outlet, which provides Mobile repair services. The charges of mobile repairs are based on the type of the service. Details of charges are as follow: Software Fault: 4 OMR Screen Fault: 6 OMR Network/Wi-Fi Fault: 8 OMR Internal Hardware Fault: 10 OMR The Outlet offers discount to the loyal customers. The discount is offered based on the customer visits to the outlet. Following is the detail of discounts. 1- Customer visiting 4 times a year gets 20% discount. 2- Customer visiting 6 times a year gets 30% discount. 3- Customer visiting 8 times a year gets 50% discount. You are required to draw a Flow Chart diagram and write a Pseudocode for a computer program that takes customer name, mobile model, visit date, total number of visits, and required service (mentioned above). The program outputs a receipt with all the entered information plus repair charges based on…In visual basic programming, write a button click even that will take a given amount in cedis and exchange rate and calculate the equivalence in US dollars when the user chooses "Yes", returns the cedi valuewhen the user chooses "No" and Zero when the user chooses "Cancel".
- You just started your summer internship with Bolts-R-Us based in Lenoir, North Carolina. You are working with the manufacturing quality control team to ensure carriage bolts produced are within specifications.For each batch of bolts produced, 10 bolts are randomly selected for testing. In order to pass quality control, the mean of the sample must be 4.00 +/- 0.125 inches and there must not be more than 2 individual bolts with lengths outside this range.Construct a program that allows an operator to enter the name of a file containing the lengths of 10 bolts randomly selected for testing. Once the 10 lengths have been read from the file, output the mean of the sample, a message indicating if the batch passes/fails based on the mean, the number of bolts outside the tolerance range, and a message indicating if the batch passes/fails based on number of bolts outside tolerance. Example Run:Enter file name: bolts.txt Mean: 3.879 PassBad Bolts: 3 FailYou just started your summer internship with Bolts-R-Us based in Lenoir, North Carolina. You are working with the manufacturing quality control team to ensure carriage bolts produced are within specifications.For each batch of bolts produced, 10 bolts are randomly selected for testing. In order to pass quality control, the mean of the sample must be 4.00 +/- 0.125 inches and there must not be more than 2 individual bolts with lengths outside this range.Construct a program that allows an operator to enter the name of a file containing the lengths of 10 bolts randomly selected for testing. Once the 10 lengths have been read from the file, output the mean of the sample, a message indicating if the batch passes/fails based on the mean, the number of bolts outside the tolerance range, and a message indicating if the batch passes/fails based on number of bolts outside tolerance.Example Run:Enter file name: bolts.txt Mean: 3.879 PassBad Bolts: 3 Fail bolts.txt data: 3.683 3.919 4.001 3.971…issignment Portion - hand in your wo nce completed "4.2 (Geometry: gneat circle distance) The great circle distance is the distance between two points on the surface of a sphere. Let(x1,y1)and(x2,y2)be the geographical latitude and longitude of two points. The great circle distance between the two points can be computed using the following formula: \[ d=\operatorname{radius} \times \arccos \left(\sin \left(x_{1}\right) \times \sin \left(x_{2}\right)+\cos \left(x_{1}\right) \times \cos \left(x_{2}\right) \times \cos \left(y_{1}-y_{2}\right)\right) \] Write a program that prompts the user to enter the latitude and longitode of two points on the earth in degrees and displays its great circle distance. The average radius of the earth is6,371.01 km. Note you need to convert the degrees into radians using the Math, toRadi ans method since the Java trigonometric methods use radians. The latitude and longitude degrees in the formula are for north and west. Use negative to indicate south and…
- Suppose that classStanding is a char variable, gpa and dues are double variables. Write a switch expression that assigns the dues as following: If classStanding is 'f', the dues are $150.00; if classStanding is 's', (if gpa is at least 3.75, the dues are $75.00; otherwise dues are 120.00); if classStanding is 'j', (if gpa is at least 3.75, the dues are $50.00; otherwise dues are $100.00); if classStanding is 'n', (if gpa is at least 3.75, the dues are $25.00; otherwise dues are $75.00). (Note that the code 'f' stands for first year students, the code 's' stands for second year students, the code 'j' stands for juniors, and the code 'n' stands for seniors.)You have just started a sales job in adepartment store. Your pay consists of a base salary and a commission. The base salaryis $5,000. The scheme shown below is used to determine the commission rate. Note that this is a graduated rate. The rate for the first $5,000 is at 6%, the next$5000 is at 8%, and the rest is at 10%. If your sales amounts to $25,000, the commissionis 5,000 * 6% + 5,000 * 8% + 15,000 * 10% = 2,200. Your goal is toearn $30,000 a year. Write a program to find the minimum sales you have to generatein order to make $30,000.Jeff and Gern run a furniture company specializing in tables and chairs. To save time, when a new order comes in, a special shorthand is used to describe the order. The rules for their shorthand are as follows • The first character is "T" for a set of tables, or "C" for a set of chairs. If the order includes both tables and chairs, the order shorthand begins with "TC" • Next they indicate the number of tables or chairs for the order. If the order includes both tables and chairs, they'll write the number of table first, then the number of chairs, separated by a dash. An order comes in for three standard tables constructed using Oakwood. What would the order shorthand be for this order?
- A loan has the following parameters: an initial balance, an interest rate and a length to pay the loan back. Please write C code to calculate an amortization schedule for specified loan terms. The formula for calculating a monthly payment is: M= P*(J + ( J/((I+J)^N*T-1))) Where: P is the initial amount of the loan R is the annual interest rate N is the number of compounding periods in a year (e.g., 12 for monthly) J is the Do not use chatgptA mobile phone service provider has three different subscription packages for its customers: Package A: For $39.99 per month, 450 minutes are provided. Additional minutes are $0.45 per minute. Package B: For $59.99 per month, 900 minutes are provided. Additional minutes are $0.40 per minute. Package C: For $69.99 per month, unlimited minutes are provided. Write a program that calculates a customer’s monthly bill. It should ask the user to enter the letter of the package the customer has purchased (A, B, or C) and the number of minutes that were used. The program should display the total charges.Complete the flowgarithm/pseudo code for the following scenario and upload into drop box Program Purpose -Professional Athletes often hire other professionals to help take care of matters for them. We will group them in four_______ categories: Lawyers, Personal Assistants, Agents, and Trainers. They all get paid a percentage of the athlete's total yearly salary. Lawyers - 10%, Personal Assistants - 3%, Agents - 7%, and Trainers - 5% .Prompt the user to enter the athlete’s salary for the year (ensure that the entered value is positive). The user should then enter the name and category of each of the hired professionals. The athlete should be able to hire at most 20 professionals in each category as he/she wants, even if it is more than he/she can afford. Based on the category, calculate the amount that each professional should be paid. After all data has been entered, print the names of each professional hired, how much each is being paid, the total amount the athlete paid, and how much…