GET MORE SOLUTION FILES FROM
[Link]
CS201P ASSIGNMENT 1 SOLUTION SPRING 2024
Due Date: 29-Apr-2024
Total Marks: 20
FOR FREE AND PAID ASSIGNMENT WITH YOUR OWN STUDENT ID
WHATSAPP +923162965677
Follow Assignment Submission Instructions
You must submit only a .cpp file on the assignments interface of CS201P from your LMS
account. Assignments submitted in any other format(image, pdf, doc, docx, etc) will be scaled
with zero marks. So, check your solution file format before submission.
GET FREE .CPP FILE FROM [Link]
CPP CODE SOLUTION:
#include <iostream>
using namespace std;
int sumOfEvenDigits(int num) {
int sum = 0;
while (num > 0) {
JOIN WHATSAPP GROUP
[Link]
GET MORE SOLUTION FILES FROM
[Link]
int digit = num % 10;
if (digit % 2 == 0 && digit != 0) {
sum += digit;
cout << digit << " ";
}
num /= 10;
}
return sum;
}
int main() {
int StudentID = 123456789;
cout << "Student ID: BC123456789" << endl;
cout << "Digital part of the Student ID: " << StudentID << endl;
cout << "Even Digits: ";
// Calculate the sum of even digits
int evenSum = sumOfEvenDigits(StudentID);
cout << "\nSum of even digits: " << evenSum << endl;
JOIN WHATSAPP GROUP
[Link]
GET MORE SOLUTION FILES FROM
[Link]
return 0;
}
CODE OUTPUT SCREENSHOT:
JOIN WHATSAPP GROUP
[Link]
GET MORE SOLUTION FILES FROM
[Link]
REGARD - SARIM
WHATSAPP +923162965677
PLEASE NOTE:
Don't copy-paste the same answer.
Make sure you can make some changes to your solution file before
submitting copy paste solution will be marked zero.
If you found any mistake then correct yourself and inform me.
Before submitting an assignment must check your assignment requirement
file.
If you need some help or question about file and solutions feel free to ask.
FOR FREE ASSIGNMENTS SOLUTIONS VISIT
[Link]
JOIN WHATSAPP GROUP
[Link]