Current location - Training Enrollment Network - Mathematics courses - Simple Mathematical Calculation of High Score in C Language
Simple Mathematical Calculation of High Score in C Language
int main()

{

Floating point a, b, c, d, e, f, g, SUM.

do

{

a = 0;

b = 0;

c = 0;

d = 0;

e = 0;

f = 0;

g = 0;

Scanf("%f, %f, %f, %f, %f, %f, %f ",& one, & c,& ampd & amp; e & amp; f & amp; g);

SUM = 1.5 * A+ 1.2 * B+ 1 * C+ 1 * D+0.7 * E+0.5 * F+0.3 * G;

printf("\n%f\n ",SUM);

}While( 1)

Returns 0;

}

For the above program, you paste it directly into a TXT file and change the extension from. Send text messages to. C, then CL it, run directly. You separate them with spaces, enter these seven numbers in turn and press Enter to get the answer, and then proceed to the next operation.