CS201 MID TERM SOLVED MCQs || PAST PAPERS || GROUP-1 || INTRODUCTION TO PROGRAMMING || VuTech Visit Website For More Solutions www.vutechofficial.blogspot.com …
CS101 ASSIGNMENT NO. 2 SPRING 2023 || 100% RIGHT SOLUTION || INTRODUCTION TO COMPUTING || BY VuTech
Visit Website For More Solutions www.vutechofficial.blogspot.com
KINDLY, DON’T COPY PASTE
Statement:
Deciding the Final Grads of various students manually is a tedious and challenging task. Your job is to develop a C++ program that should be capable of calculating the Total and Average Marks of a student. Based on the above calculations the program should award the correct Final Grad to a student.
The program should allow the users to enter their OWN VU-ID and any random marks for four subjects CS, Math, Pak Study, and MGT. Then, the Total marks and Average Marks are calculated using mathematical operators on variables for each subject. The program should use Control Structure “if or ifelse” and “Logical Operator(s)” to decide the final grad of a student based on the Average Marks. Also, the following score limits should be implemented in your program to grant Correct grad to a student as per the following upper and lower score bounds/limits. For example, if a student got Average Marks 86 then Grad “A- “should be awarded
Lower and upper bounds for grads:
91 to100 => Grad: A+
81 to 91 => Grad: A71 to 81 => Grad: B+
61 to 71 => Grad: B51 to 61 => Grad: C
41 to 51 => Grad: D
35 to 41 => Grad: E
34 to 0 => Fail
Program:
#include <iostream>
using namespace std;
int main() {
string vuID;
int csMarks, mathMarks, pakStudyMarks, mgtMarks;
// Input section
cout << "Enter your VU-ID: \n";
cin >> vuID;
cout << "Enter Marks of CS: \n";
cin >> csMarks;
cout << "Enter Marks of Math: \n";
cin >> mathMarks;
cout << "Enter Marks of Pak Study: \n";
cin >> pakStudyMarks;
cout << "Enter Marks of MGT: \n";
cin >> mgtMarks;
// Calculation section
int totalMarks = csMarks + mathMarks + pakStudyMarks + mgtMarks;
KINDLY, DON’T COPY PASTE SUBSCRIBE, SHARE, LIKE AND COMMENTS FOR MORE UPDATES SEND WHATSAPP OR E-MAIL FOR ANY QUERY 0325-6644800 kamranhameedvu@gmail.com Visit Website For More Solutions www.vutechofficial.blogspot.com
We provide Virtual University of Pakistan Study Materials such as Solution of Assignments, GDBs, Mid Term Solved Papers, Final Term Solved Papers, Mid Term Solved MCQs, and Final Term Solved MCQs. We also provide regular Semester Quizzes, Updated Handouts, and Short Questions and Answers. We help you with your research and many other educational-related topics, as far as we know. Furthermore, Share your problem with us and Please feel free to ask any related questions.