This program will calculate the average(%) of exam grades.
It will also add extra credit points to the exam average given the course difficulty.
Enter all of the grades for one student. Type (-1) when finished with that student.
If you have additional students, you will be prompted to repeat the program at the end.
Enter an exam grade (type -1 to quit): user types: ten
Error: Grades must be an integer 0 or higher.
Enter an exam grade (type -1 to quit): user types: 100
Enter an exam grade (type -1 to quit): user types: 50
Enter an exam grade (type -1 to quit): user types: -1
Exam average, including extra credit, is: 78
The equivalent letter grade is: C
Would you like to enter grades for another student (Y or N)? user types: N
This program will calculate the average(%) of exam grades.
It will also add extra credit points to the exam average given the course difficulty.
Enter all of the grades for one student. Type (-1) when finished with that student.
If you have additional students, you will be prompted to repeat the program at the end.
Enter an exam grade (type -1 to quit): [user types: 100]
Enter an exam grade (type -1 to quit): [user types: 90]
Enter an exam grade (type -1 to quit): [user types: 80]
Enter an exam grade (type -1 to quit): [user types: -1]
Exam average, including extra credit, is: 93
Melokuhle is a very young intelligent and adventurous individual. He has recently bought 4 quantums (taxi) to transport people around the country. As a result, he is planning a trip to Upington. Therefore, he has hired you to write a program in pseudocode as well as in C++ to evaluate the fuel consumption on his 4 cars during the planned trip. The kilometers and fuel level in the tank at the start and end of the journey should be entered by the end-user. Calculate for each car, the fuel used, kilometers traveled, and the overall fuel consumption in kilometers traveled per litre of fuel.
Melokuhle is a very young intelligent and adventurous individual. He has recently bought 4 quantums (taxi) to transport people around the country. As a result, he is planning a trip to Upington. Therefore, he has hired you to write a program in pseudocode as well as in C++ to evaluate the fuel consumption on his 4 cars during the planned trip. The kilometers and fuel level in the tank at the start and end of the journey should be entered by the end-user. Calculate for each car, the fuel used, kilometers traveled, and the overall fuel consumption in kilometers traveled per litre of fuel.
Melokuhle is a very young intelligent and adventurous individual. He has recently bought 4 quantums (taxi) to transport people around the country. As a result, he is planning a trip to Upington. Therefore, he has hired you to write a program in pseudocode as well as in C++ to evaluate the fuel consumption on his 4 cars during the planned trip. The kilometers and fuel level in the tank at the start and end of the journey should be entered by the end-user. Calculate for each car, the fuel used, kilometers traveled, and the overall fuel consumption in kilometers traveled per litre of fuel.
When analyzing data sets, such as data for human heights or for human weights, a common step is to adjust the data. This adjustment can be done by normalizing to values between 0 and 1, or throwing away outliers.
For this program, adjust the values by dividing all values by the largest value. The input begins with an integer indicating the number of floating-point values that follow.
Output each floating-point value with two digits after the decimal point, which can be achieved by executing
cout << fixed << setprecision(2); once before all other cout statements.
Ex: If the input is:
5 30.0 50.0 10.0 100.0 65.0the output is:
0.30 0.50 0.10 1.00 0.65 Write a program to find length of string by using pointers
Add each element in origList with the corresponding value in offsetAmount. Print each sum followed by a space. Ex: If origList = {40, 50, 60, 70} and offsetAmount = {5, 7, 3, 0}, print:
45 57 63 702. Design a class Account that has the following member: Data Fields: account_id(int type), balance(double type)).
Member Functions-> withdraw(),deposit(),getmonthly_interest() and parameterize constructor to initialize data members. Use this class to print the balance. Use the withdraw () to withdraw money less than Rs 5000 and then deposit more than or equal 1500 using deposit function. (6)
. Write a C++ program that reads 10 characters from user (user can type any character i.e., small or capital alphabets, digits, special characters). Convert all small alphabets to capital alphabets and capital alphabets to small alphabets. Store each type of character in separate arrays i.e., small alphabets in separate array, digits in separate array etc.
■ Provide a menu with the following options to the user,
Menu
Press 1 to Input the array
Press 2 to process the array [as per the requirements provided above]
Press 3 to print the capital letters
Press 4 to print the digits
Press 5 to print the special characters
■ Use the appropriate fundamental programming constructs i.e., variables, control-flow, loop, functions etc.