write a program c++ A General: Service company hired you to write a program to compute the total charge for the services rendered to their client. The program will ask first if there is a material needed or not. If there is, the program will ask if what material is needed. The program will then ask for the cost of that materials entered and the number of hours of the services rendered. Finally, the program will compute for the labour cost and the total charge.
Q: in C++ Write a program to call two functions: 1. Sum four integer numbers 2. calculate the averages…
A: Actually, program is an executable software that runs on a computer.
Q: Write a C program that takes a command line argument of a number that you need to calculate the…
A: Hey there, I am writing the required solution based on the above given question. Please do find the…
Q: Programing in c This program will calculate how pricy two products will be in 2030. It will begin by…
A: Note: Comments have been included in the source code itself to have a better understanding of the…
Q: write in c programming Q# 3. Implement a Tour Planner and Budget Calculator for Holidays. Program…
A: Declare necessary variables. Read input from the user such as number of persons, number of days, and…
Q: PROBLEM: Write a C++ program that will allow the user to input the First Name, Last name, Middle…
A: - We need to create the grade program.
Q: write a program in c++. You work for a box company, and have been asked to write a program to…
A: PROGRAM INSTRUCTIONS: The C++ program has the following algorithm: Declare and initialize the…
Q: Write a C program that takes a command line argument of a number that you need to calculate the…
A: Answer:- #include<stdio.h>#include <stdlib.h>long int factorial(int n) { if (n>=1)…
Q: 1. Write a complete C++ program that asks the user to type a big integer n. It should then ask 4…
A: Given:
Q: 2. Write a C++ program to play a guessing game: • The computer randomly generates a number between 1…
A: #include <iostream> using namespace std; int main(){ //declare variables int i,n,num;…
Q: write a program in c++. You work for a box company, and have been asked to write a program to…
A: Hi student, hope you are doing well. This question is about writing a C++ program to display a table…
Q: Write a C program that takes a command line argument of a number that you need to calculate the…
A: Create an input directory and new file using nano command as shown below:
Q: Write a progarm in C compiler that inputs three variable from the user of type: int, float and char.…
A: Please find the answer below :
Q: Write a C program that takes a command line argument of a number that you need to calculate the…
A: Given: Write a C program that takes a command line argument of a number that you need to calculate…
Q: PROBLEM: Write a C++ program that will allow the user to input the First Name, Last name, Middle…
A: #include <iostream>using namespace std; int main(){ string FirstName, LastName,…
Q: Question (1): Write a program in C++ language to print on the screen of computer the numbers obtain…
A: START DECLARE i PRINT "Enter the value of i: " INPUT i PRINT "Value of 2i is " DISPLAY 2*i STOP
Q: In C programming language, if the first and the second operands of operator + are of types int and…
A: Question Given:- In C programming language, if the first and the second operands of operator + are…
Q: Writing a Modular Program in C++ BadDate.cpp 19 // This is the work of the housekeeping() method //…
A: The program is written in C++. Please find the program code and flowchart in the below steps.
Q: Question #3: Write a C program that repeatedly asks the user to enter real numbers from the…
A: The C program needs to read integer values repeatedly. To read numbers repeatedly, we need a loop to…
Q: Write a C++ program to develop a Vehicle Fine Management System for Police. The program will have…
A: Note: As you have asked multiple questions, as per our policy we will solve the first question for…
Q: Write a C++ program that stores data of students in a struct. It should store student's ID,…
A: The C++ program : #include <iostream>using namespace std;// student structurestruct student{…
Q: in C++, the definition of any variable (e.g. int x;) tells the compiler about ________. all of…
A: int x; Here int x means data type is integer and variable name is x. If it is int x=5; This means…
Q: Write a C program that takes a command line argument of a number that you need to calculate the…
A: #include<stdio.h> #include <stdlib.h> long int factorial(int n) { if (n>=1)…
Q: write a program in c++. You work for a box company, and have been asked to write a program to…
A: Below is the required C++ program. Program Approach: Include necessary header files and using the…
Q: Write a C program that takes a command line argument of a number that you need to calculate the…
A: GIVEN:
Q: wite in c programming Q # 2. Illustrate your knowledge of C-Control Structures and implement an…
A: C Program: #include <stdio.h>int main(){ double price,total_bill=0.0; int unit; char…
Q: write a program in c++. You work for a box company, and have been asked to write a program to…
A:
Q: Write a C++ program to develop a Vehicle Fine Management System for Police. The program will have…
A: As you have asked multiple questions, as per our policy we will solve the first question for you.…
Q: This must be set up in C programming language. PLEASE include comments in the code to teach me how…
A: Your C program is given below as you required with an output.
Q: Write a C program that takes a command line argument ofa number that you need to calculate the…
A: Given: Please also explain how to put the input.
Q: PROBLEM: Write a C++ program that will allow the user to input the First Name, Last name, Middle…
A: 1)Read the input from the user first name, last name, middle initial and Grade 2)Display the first…
Q: Write a C++ program to calculate a rectangle's area. The program consists of the following function:…
A: C++ program to calculate a rectangle's area. The program consists of the following function: ⚫…
Q: Write a unit conversion program in C++ that asks the users from which unit they want to convert…
A: Actually, program is a executable software that runs on a computer.
Q: write a program c++ A General Service company hired you to write a program to compute the total…
A: The following is the formula to calculate the material cost and labour cost of construction and…
Q: 4. Write a C++ program to implement the Number Guessing Game. In this game the computer chooses a…
A: Write a C++ program to implement the Number Guessing Game. In this game the computer chooses a…
Q: 2. Write a C++ program to play a guessing game: • The computer randomly generates a number between 1…
A: // Code #include <iostream>#include <stdlib.h> using namespace std; int main(){ int…
Q: Write a C++ program to develop a Vehicle Fine Management System for Police. The program will have…
A: Note: As you have asked multiple questions, as per our policy we will solve the first question for…
Q: PROBLEM: Write a C++ program that will display a menu consisting of 3 brands of soda, 3 kinds of…
A: Code: #include <iostream>#include <cstdlib>#include <iomanip>using namespace std;…
Q: Write a complete C++ program that calculate a patient's treatment charge based on the types of…
A: C++ code for the requirement: #include <iostream>using namespace std; float…
Q: In my C++ program, I am trying to write code that will check command line arguments for "-amount"…
A: Note:The expression “floor(x)-x!=0” can be used to check whether the value of “x” is a double…
Q: C Programming Write a program that reads an integer from the user (keyboard), namely n. Your…
A: As per the given problem statement we are required to develop a C code which take an input of…
Q: a C++ program that computes the sum of the integers from 1 up to an integer provided by the…
A: function main: Start declare i, sum = 0, number read number for i = 1 to number follow step 5 sum =…
Q: Write a C++ program to develop a Vehicle Fine Management System for Police. The program will have…
A: Vehicle Management System would require the use of: Switch Statements Functions Objects The…
Q: Write a C program that takes a command line argument of a number that you need to calculate the…
A: // C code ://include necessary packages#include <stdio.h>#include <string.h>//Function…
Q: Program in C: Create a program that tells you how much money you have left after some expenses. Use…
A: Program: //include the header file #include <stdio.h> //definition of "aaa" function int aaa…
Q: Write a C program that plays the game of "guess the number" as follows: your program should be…
A: A required program is as follows, #include <stdio.h> #include <stdlib.h> #include…
Q: write a program c++ A General Service company hired you to write a program to compute the total…
A: Given: Assumption: Rate $45.00 per hourComputation: Labour : Rate * hours work Total…
Q: Write a C++ program to develop a Vehicle Fine Management System for Police. The program will have…
A: Note: As you have asked multiple questions, as per our policy we will solve the first question for…
Q: Write a c++ program to display a calendar for a given year. Type of Branches such as switch…
A: PROGRAM STRUCTURE: Include all the required header files. Write a function that gives out the index…
Q: Hello! Write a C++ Program that simulates a basic calculator using functions which performs the…
A: Solution:Given data,The C++ code to perform the calculator operations using function is given…
Trending now
This is a popular solution!
Step by step
Solved in 2 steps
- Write a complete C++ program that asks the user to input information for at least 10 students. Use structure for the information below: Name of the student, Matric No, Course No, Obtained Marks The program should then display the information based upon marks in ascending and descending order. To solve ascending and descending order the program should have two functions that have an array of structure as a parameter and the functions should be called from the main function.Please answer in C++ Code Admission to college is just beginning and Chef has also just finished his high school. There are NN colleges, listed from 11 to NN, and listed from 11 to NN. Each college has only one seat left. To apply for a college, each student must submit the same examination, the result of which determines their future, that is, the best student (the highest scorer) gets the first choice of college. Each student has a list of favourite colleges. They will want to get to the top ranked college on their list. If they can't get into it, they'll want to get into a second-ranked college in the middle of their list, and so on. If one vacant college seat is filled, that year's admission closes at that college. Then, people who have applied for that college should look for a lower college in their preferred list as long as it still has vacancies. Looking at the information about MM students, about their exam scores (given as standards) and the college IDs they apply for, find…C++ Write a program that simulates the minute-by-minute operation of a checkout line, such as one you might find in a retail store. Use the following parameters: Customers arrive at the checkout line and stand in line until the cashier is free. When they reach the front of the line, they occupy the cashier for some period of time (referred to as ServiceTime) measured in minutes. After the cashier is free, the next customer is served immediately. Customers arrive at the checkout line at ArrivalRate per minute. Use the function included below (customerArrived()) to return the number of customers arriving in a given minute, determined randomly. The line can only hold so many people, MaxLineSize, until new arriving customers get frustrated and leave the store without purchasing anything. The overall time of the simulation is SimulationTime, measured in minutes. The program should take 5 inputs (to be read from a text file named simtest.txt, one per line): SimulationName - a string…
- Programing C Just with #include Matrix Addition and Subtraction (Associatively) Write a program that performs matrices addition and subtraction. As shown in the example below, you have to ask the user for the number of rows and number of columns that both matrices should have (they both have to be the same size, that is why you only ask once). You will then ask the user for the values of each matrix. Then, you will print the values that the user inputted, the added values of both matrices, and the subtracted values (matrix 2 should be subtracted from matrix 1). In this challenge Guidelines/steps: • The number of rows and the number of columns should be global variables. • Once you get these two from the user, you should declare your two matrices in main. • Then, from main, you will call function aaa twice; first, you will send matrix 1 and populate it with values inputted by the user. You will call the function a second time, send matrix 2 and populate it. In other words, function aaa…IN C++ Write a program that computes the Greatest Common Factor for any given two values. The user should be able to enter as many values (sets of two) as needed. The program should do the following: 1. Allow the user to enter as many values as needed. 2. After the user enters all the values, the program displays each pair of values and the GCF. 3. The function to find GCF must be a recursive function. Here is the definition that you must use: GCF (n,m) = m if min c++ In this exercise, we will read in a data file of employees (file is furnished to you, “employee.dat”): Employee SSN Employee Last Name Employee First Name Hours Worked Pay Per Hour Personal Income Tax Rate You assignment’s logic is to: Read in the records from the file, Pass the Hours Worked, Pay Per Hour, Personal Income Tax Rate to a single function to determine: Whether or not overtime pay is computed (anything over 40 hours is overtime at 1.5 times the regular pay). Compute any overtime pay at 1.5 times pay rate Compute the regular pay at regular hours (40 hours or less) Compute the gross pay (Regular Pay plus any overtime pay) Compute the personal income taxes withheld Compute Net Pay (gross pay minus personal income taxes withheld) Pass ALL these values BACK to the main calling routine from this one function. Display: the Employee SSN, Last Name, First Name, Total Hours, Regular Hours, Overtime Hours (if any), Pay Per Hour, Personal Income Tax Rate, Regular Pay,…
- Write a complete C++ program to help the manufacturer determine the greatest profit obtain from making tables and chairs with a given number of M type A and N type B wood blocks. • The program should prompt the user to input M and N. • Then tabulates all the combinations of tables and chairs possibly made, and calculates the profit obtain using array. • The program should also identify the greatest profit and make a concluding remark. • The program should be written in modular form with the main() function calling other functions. If arrays are involved in the function, the arrays should be passed into the function as parameters. • Lastly, display the output to an external .txt file.C LANGUAGEA private railway company has just purchased a computer for its new automated reservationssystem. You have been asked to write a program to assign seats on each train of the railway havingonly (capacity: 100 seats). Your program should check whether it is a valid seat number or not.Also print its berth type i.e lower berth, middle berth, upper berth, side lower berth, side upperberth. Furthermore, then print a ticket indicating the person's seat number and whether it’s in the firstclass or economy section of the train. Use a single-subscripted array to represent the seating chartof the train. Initialize all the elements of the array to 0 to indicate that all seats are empty. As eachseat is assigned, set the corresponding element of the array to 1 to indicate that the seat is no longeravailable.Chapter 4 write a program in C++ language to name a row with the name (Count) to calculate the number of inhabitants of the city of N as a function of the number of years T, noting that the primary population N is 3 million people and that the city is subject to the following population growth equation: N = Z (No + (700 -) No) exp
- Language C++ It has been observed by management that some faculty member at the university demonstrates a lackadaisical attitude toward teaching. They seldom go to class yet at the end of each month they receive full salary. Management has decided that GHs 200, 300, 400, and 500 will be deducted from a faculty’s salary if he/she offends once, twice, third time and forth time respectively in a month. This means that if a faculty member offends once in a month GHs 200 will be deducted, if a faculty member offends twice in a month, GHs 500 (i.e. 200+300) will be deducted, if a faculty member offends three times in a month GHs 900 (i.e. 200+300+400), will be deducted and if a faculty member offends four times in a month GHs 1,400 (i.e. 200+300+400+500). Assuming all faculty members are on a flat salary rate of GHs 2000. a. Write a program to request for the names of four faculty members and number times he/she has absented him/herself from class. One of them should have absented…Needs to be done in C# language. Problem Write a program that computes and displays the charges for a patient’s hospital stay. First, the program should ask if the patient was admitted as an in-patient or an out-patient. If the patient was an in-patient, the following data should be entered: • The number of days spent in the hospital• The daily rate• Hospital medication charges• Charges for hospital services (lab tests, etc.) The program should ask for the following data if the patient was an out-patient: • Charges for hospital services (lab tests, etc.)• Hospital medication charges The program should use two overloaded functions to calculate the total charges. One of the functions should accept arguments for the in-patient data, while the other function accepts arguments for out-patient information. Both functions should return the total charges. Input Validation: Do not accept negative numbers for any data.Write in C++ 1. Define a struct for a soccer player that stores their name, jersey number, and total points scored. 2.Using the struct in #1, write a function that takes an array of soccer players and its size as arguments and returns the average number of points scored by the players. 3.Using the struct in #1, write a function that takes an array of soccer players and its size as arguments and returns the index of the player who scored the most points. 4.Using the struct in #1, write a function that sorts an array of soccer players by name. 5.Using the struct in #1, write a function that takes an (unsorted) array of soccer players and its size and a number as arguments, and returns the name of the soccer player with that number. It should not do any extra unnecessary work. 6.Define a function to find a given target value in an array, but use pointer notation rather than array notation whenever possible. 7.Write a swap function, that swaps the values of two variables in main, but use…