#include void main(void) { /* The simple program that finds the class average of 10 students who wrote a quiz using simple while structure */ int mark, sum, knt; float average; /* initialize the control variable and ohters */ sum = 0; knt = 0; /* test for loop continuation using control variable */ while (knt < 10) { printf("type the %d mark \t:", knt); scanf("%d", &mark); sum += mark; /* Now update the control variable */ knt++; } average = (float) (sum/knt); printf("average = %0.2f \n", average); }