Question: Question 2 a. Write a C program to read marks of N subjects and find Total, Average and Percentage marks. Your program should implement the

 Question 2 a. Write a C program to read marks of

Question 2 a. Write a C program to read marks of N subjects and find Total, Average and Percentage marks. Your program should implement the following functions getMarks0 this function will collect all the marks that are to be used in calculations calculateAverage0 this function calculates the average or mean of the marks b. Write a program in C to draw a circle on screen using graphics.h header file In this program, draw a circle on screen having centre at mid of the screen and radius of 80 pixels You may find the detailed descriptions of graphics functions below useful. Function Deciption initgraph I iniializes the graphics system by loading the passed graphics driver then changing the system into graphics mode. getmaxx It returns the maximum X coordinate in current graphics mode and driver getmaxyIt returns the maximum Y coordinate in current graphics mode and driver Quttextxx It displays a string at a particular point (xy)on screern circle closegraph It unloads the graphics drivers and sets the screen back to text mode. It draws a circle with radius r and centre at (x, y). For Example 100 in Decimal is equivalent to 1100100 in Binary number system. Algorithm to convert Decimal to Binary number Divide the input decimal number by 2 and store the remainder Store the quotient back to the input number variable Repeat this process till quotient becomes zero. Equivalent binary number will be the remainders in above process in reverse order For Example Suppose input decimal number is 13 Step 1. 13/2, Remainder 1, Quotient 6 Step 2-62 , Remainder = 0, Quotient-3 Step 3. 3/2, Remainder 1, Quotient 1 Step 4. 1/2, Remainder-1, Quotient 0 Now, the Binary equivalent of 13 is the remainders in reverse order 1101 d. Write a C program to convert a decimal number to binary number [0] e. Consider multiplication as repeated addition and the write a function multiply(x.v) that will implement recursion to do this multiplication

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!