Question: Define a class named StudentInfo that contains the attributes age and id . Initialize age and id with 0 . Click here for example Ex:
Define a class named StudentInfo that contains the attributes age and id Initialize age and id with
Click here for example
Ex: If the input is:
then the output is:
Student info before: years old, #
Student info after: years old, #
Your code goes here
newstudent StudentInfo
printStudent info before: end
printfnewstudent.age years old, end
printf#newstudent.id
newstudent.age intinput
newstudent.id intinput
printStudent info after: end
printfnewstudent.age years old, end
printf#newstudent.id
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
