WRITE A PROGRAM IN C++ TO CALCULATE THE PRICE OF AN ITEM COSTING 100 GHANA CEDIS AFTER A DISCOUNT OF 10% IS APPLIED TO IT.
Q: Write a C# program that prints a table with a list of at least 5 students together with their grades…
A: Please find the answer below :
Q: From Dynamic programming d. In dynamic programming, the technique of storing the previously…
A: Question d. In dynamic programming, the technique of storing the previously calculated values is…
Q: Exercise : Write a C++ program that computes and returns: • the smallest positive integer (n) for…
A: Program Approach: Including a necessary header file Defining method compute Declare variable 0 to n…
Q: Write a C++ program that calculates and displays the avarage mark (in percentage - %) of 3 modules…
A: I have provided solution in step2
Q: An organization has two types of employees: regular and adhoc. Regular employees get a salary which…
A: Program code: #include <iostream>#include <string>using namespace std; //The Employee…
Q: Complete the program in Fortran 90 language for the following series. Sin (x)=x?++ +...
A: The answer for the given question is as follows
Q: Write a C Program that ask the user to choose from 2 categories, then ask the user to enter two…
A: C Code for computation of greatest or smallest number is in step 2.
Q: Write a program in c# that plays a guessing game with the user. Have your program read and store an…
A: C# program for the given problem:
Q: Problem: Write a C++ program for discount computation that can be used in a store. However, only…
A: #include <iostream> using namespace std; int main() { int amount; double discount;…
Q: Write a C program that uses a recursive function to calculate power.
A: The code to find n^p using recursive methods in C is given below - In this code, the recursive…
Q: Write a C++ program which stores names of five cities and print the names of only those cities which…
A: Actually, program is a executable software that runs on a computer.
Q: Write a C program to validate operators (all operators, such as assignment operators, misc…
A: Operators in C are of different types below code demonstrate all kinds of operators.
Q: Write a c program that calculates a degree classification such that number of modules used for the…
A: ALGORITHM:- 1. Take input for the marks of 10 subjects from user. 2. Calculate the total of all the…
Q: Write a program in C++ to handle the following scenario: Following is a list of tablets available in…
A: Arrays are utilized to hold multiple values in a single variable. Syntax of declaring an array :…
Q: Write and execute a program in C++ that will count from 1 to 21 and print the count, and its cubed…
A: A C++ program is as follows, #include <iostream> //Declare namespace using namespace std;…
Q: Writing a C ++ program that converts the temperature from F to C using the concept of functions,…
A: Program description: f is the user input integer variable that takes the temperature on the…
Q: Write a C program to simulate tossing a “fair” coin. Allow the user to enter the number of tosses.…
A: Generate random number and divide with 2 If remainder is 0, consider it as HEADS or else TAILS
Q: Write a basic C program in which a user enters the marks scored by him out of 100 in 5 subjects…
A: Initialise an integer variable with value 0 to store the sum of marks obtained in all 5 subjects.…
Q: Write a C++ program to declare a char variable ch with the value 'z' without using the assignment…
A:
Q: Write a C++ program that generates a conversion table from francs to dollars. It starts with the…
A: Here I have first of all declared a variable to store the conversion rate from francs to the dollar.…
Q: Write a C++ program that determines whether an integer number is positive, negative or zero using…
A: USING FUNCTION #include<iostream> using namespace std; // function declaration void…
Q: Write a program in C++ that reads three numbers and finds the middle value between them?
A: C++ program that reads the middle value between them
Q: Write a c++ program that reads a matrix of real values where the number of lines and the number of…
A: C++ Program for above : #include <iostream> using namespace std; int main() { int row,…
Q: Write a C++ program to read two values (name and degree) for ten students and print the name and the…
A: This program will create a structure for the name and marks/degree of the student and then I have…
Q: Write a program in c Food Ordering System using Function, Structure, Pointer, File, Array, String,…
A: #include <stdio.h>int main(){ while (1) { printf("\n\nWelcome to Food ");…
Q: Write a program in C++ language to find the average age of a group of 11 players, ask the age of…
A: Given: Age of 11 players. Requirement: Write a C++ program to take input age of players and print…
Q: Write a C program that reads the exam data for each student in a line to be entered from the…
A: Answer in step2
Q: Write a program in perl to demonstrate the use of until loop with example of printing capital…
A: This question is from the perl programming language which was developed for text manipulation. The…
Q: Write a C++ program in which a shop will give discount of 10% if the cost of purchased quantity is…
A: According to the Question below the Solution: Program Output:
Q: Write a c program that computes the square footage of a house given the dimensions of each room.…
A: EXPLANATION: - double readRoomDimensionAndComputeArea(): - The user is given the prompt to enter…
Q: Write a C++ program in which accepts the user's first and last name and print them in reverse order…
A: Write a C++ programme accepts the user's First and last name and Printthem in recerse order with a…
Q: Display following menu given below. Enter p for Panadol Enter d for Disprin Enter c for Calpol Enter…
A: Editable Code in C++ :- #include <iostream> using namespace std; int main() { //Menu…
Q: Q.1/Write a program in C++ language that introduces the salaries of ten teachers in five departments…
A: Use a 2-D array to store salaries of 10 teachers of 5 departments
Q: What are the advantages and disadvantages of passing parameters in a C program instead of using a…
A: Parameter passing allows the user to use value of local variables which were declared within main…
Q: 4- Write a program in C++ to find the value of Y for the following relationship: Y = (x3 + 1) 1/2 +…
A: Hello Student, Greetings Hope you are doing great. I will try my best to answer your question. Thank…
Q: Write a program in the language of two people in a 1:3 ratio, if the heir is male, the share is…
A: Introduction Input : Heir type Amount Output : Share of parents and heir
Q: Write a C++ program in which accepts the user's first and last name and print them in reverse order…
A: #include <iostream>#include <string>using namespace std; int main(){ string first, last;…
Q: Design a program in C++ that can withdraw and deposit into an account also add or deducts the total…
A: Introduction: Here we are required to design a program in C++ that will function like a bank with…
Q: Write a C program for a match-stick game between the computer and a user. Your program should ensure…
A:
Q: Write a value function in a C++ program that has two double parameters, calculates their difference,…
A: To perform the given task, the planning of the program can be done as : Define a function named…
Q: Write a C++ program that: The first function is a default constructor which initializes sum and…
A: According to the question below the Complete Program:
Q: Write a program (C,C++ or any other language) where a shop owner can input daily sales and calculate…
A: I am using c++ Algorithm: Start Read no.of days n Read sales for n days in an array a Read price of…
Q: Write a computer science Java program that is a compound-interst application. repeast steps for…
A: import java.util.Scanner; class Main { public static void main(String[] args) { Scanner input =…
Q: Write a program to Design a simple lexical analyzer in C++ which reads the following source code and…
A: lexical.cpp…
Q: Write a program in c++ that declares the average testscore and total test score.
A: Algorithm: Start Open testscore.txt file Initialize count to 0 and sum to 0 and i=0 Read each line…
Q: Write a c++ program that asks the user to enter two words of English language and compare them…
A: PROGRAM: //Header file #include <iostream> #include <algorithm> #include <cstring>…
Q: Write a c program to find the gross salary of an employee after taking basic salary, HRA, DA from…
A: Start Take the input of basic salary Compute the gross salary Print gross salary Stop
Q: Write a C Program to calculate simple interest after taking principal amount, rate, time from the…
A: Required:- Write a C Program to calculate simple interest after taking principal amount, rate, time…
WRITE A
Step by step
Solved in 2 steps with 1 images
- write a program in C++ that A user needs to determine the size of squares (let say delta) in a grid, the center of the circle (does not have to lie on a grid but it can!) and the radius. (for example use "cin>>" ) Then you need to plot a circle using parametric equations of circle (you need to increase angle and plot these (in my picture black) points). First plot the first point of the circle and determine in which square of grid it is. (in my picture it is an orange square) and plot the left bottom vertex of this square (in my picture it is a blue point). Then increase an angle and plot next point of circle - check if it lies in different square. -If it is not in different square, you need to increase angle and check again. (because an angle was too small) -If it is the different square, then check, if this square has THE COMMON EDGE with the previous one -> if it has the common edge, then print new left bottom vertex of this square (if does not have common edge,…In this c++ program you are asked to design a 2 x 2 x 2 Rubik's cube that is filled with numbers instead of colors. The cube, naturally, has six sides that are identified as follows: The front side is side 0 The right side is side 1 The backside side is side 2 The left side is side 3 The Up side is side 4 The bottom side is side 5 The squares on every side are initially filled with the same side index. This means that the four squares on the front side are filled with 0's, the four squares on the right side are filled with 1's, etc. You are allowed to move the cube in two directions only: Horizental move (H or h): The first row moves one step in four sides in this order (0 -> 1 -> 2 -> 3 -> 0) Vertical move (V or v): The left column moves one step in four sides in this order ( 0 -> 5 -> 2 -> 4 -> 0) The program accepts from the the user the number of moves he/she wants to make, accepts the sequence of desired moves as shown in the sample case below.…write a program in c++ in which A Paint Company has asked you to write an application that calculates the quantity and price of Paint required to a paint for rectangular rooms in a building. To calculate the quantity of paint required, you have to first calculate area of room, assuming one gallon is enough for 120 square feet. Then for price you multiply the quantity of paint by the price per gallon. For example, the area of room that is 34 square feet. To cover that room with paint that costs 1000 per gallon would cost (1/120*34=2.83 gallon, 2.83*1000=2833rs).(you can take help from internet for exact formulas) First, you should create a class named RoomDimension that has two attributes: one for the length of the room and one for the width. The RoomDimension class should have a member function that returns the area of the room. Once you have written the class, use them in an application that asks the user to first enter total number of rooms, create a dynamic array, then ask user to…
- The Goal of this project is to write a program in C++that calculates car rental amounts (for an online 24/24 service).The rental rates are as follows: •From 00:00 am to 06:59 am and from 17:00pm to 24:00pm: 8 dollar/hour •From 07:00 am to 16:59 pm: 10 dollars/hour The program will ask the user to enter the start and end hours of the rental as integers and will compute and display the rental cost. You will adopt the following simplifications: •the hours are integers (we don’t mind about minutes; each started hour will be fully paid); •the start time (i.e., hour) of the rental period must always be less than the end time (i.e., hour) of the rent. This means that one cannot hire a car for more than 24 hours and that each rental period must lie within the same day.Write a program in C++ to simulate a 1-dimension random walk along a circular tiled path. At each step, the walker randomly selects, with equal probability, to move to the left or right. The program displays the walker’s progress as it moves from tile to tile. The simulation ends as soon as the walker visits each tile at least once. The program displays the number of times the walker visited each tile. The program displays the number of times the walker moves.Write a program in C++ to calculate and print the Electricity bill of a given customer. The customerid, name and unit consumed by the user should be taken from the user and display the totalamount to pay by the customer. The charges are as follow:Unit Charge per unitUp to 199 @1.20200 and above but less than 400 @1.50400 and above but less than 600 @1.80600 and above @2.00Example: If user enter 199 unit then the electricity bill will be 199 *1.20 = 238Output will display customer id, name, unit consumed and total amount of bil
- In C++: The members of the board of a small university are considering voting for a pay increase for their 100 faculty members. They are considering a pay increase of 5%. Write a program that will prompt for and accept the current salary for each of the faculty members, then calculate and display their individual pay increases. At the end of the program, print the total faculty payroll before and after the pay increase.In C++ Write a program that can be used to calculate the federal tax. The tax is calculated as follows: For single people, the standard exemption is $4,000; for married people, the standard exemption is $7,000. A person can also put up to 6% of his or her gross income in a pension plan. The tax rates are as follows: If the taxable income is: Between $0 and $15,000, the tax rate is 15%.Between $15,001 and $40,000, the tax is $2,250 plus 25% of the taxable income over $15,000.Over $40,000, the tax is $8,460 plus 35% of the taxable income over $40,000. Prompt the user to enter the following information:Marital statusIf the marital status is “married,” ask for the number of children under the age of 14Gross salary (If the marital status is “married” and both spouses have income, enter the combined salary.)Percentage of gross income contributed to a pension fund Your program must consist of at least the following functions:Function getData: This function asks the user to enter the…Write a program using C++ for the following: A program that allows students to register their information It should include their first name, last name, department, faculty, grades for all courses. For Student Grades, courses are graded out of 100%, so an example of a valid score is 70. There should also be a field to check if a student is active or inactive, and if receiving government tuition assistance. Finally, they should be able to check their grades for their academic life.
- Write a c++ program for a bank in your town that updates its customers’ accounts at the end of each month. The bank offers two types of accounts:savings and cheque. Every customer must maintain a minimum balance.Minimum balances for the accounts are: Savings : R 1000.00 Cheque: R 1500.00If a customer’s balance falls below the minimum balance, there is a service charge of R50.00 for savings accounts andR100.00 for cheque accounts. If the balance at the end of the month is at least the minimum balance, the clientreceives interest as follows: Savings accounts receive 4% interest on the balance. Cheque accounts with balances of up to R 5000.00 more than the minimum balance receive 3% interest;otherwise, accounts with balances more than R 5000.00 more than the minimum balance receive 5% interest.Write a c++ program that requests the user to enter a customer’s account number (int type), account type (char type - S for savings, C for checking) and current balance. The updated balance must…Write a C++ program that calculates and displays the avarage mark (in percentage - %) of 3 modules for 30 students in a class. The student name and the marks for 3 modules must be inputed by the user. Only display a list of students who has a pass avarage of 50% or higher.Write a C++ Program using using classes, that, given a number greater than zero (0), the user will choose to calculate one of the following values: the fibonacci series up to that number, where any number in the sequence is the sum of the previous two numbers: F, = Fn-1+ Fn-2, where F, = 0; F = 1 the sum of the numbers up to that number, given by the equation: nx(n+1) 21 the inverse square series up to that number, given by the equation: (-) the Sum of alternating sign Squares up to that number, given by the equationZ-1W+1) x n² the Sum of the factorial to the power of the number, given by the equation: () Each option should have its own class. A class can call another class. Use a class to validate your input.