C language programming, who helped compile the next
Users questions: Demand S = 1 +1 * 3 +1 * 5 + ... 1 * (2n-1), n from the keyboard input, with the loop only as C-loop learning in Chapter 6, it is not too deep over the
Experts answer: # include stdio.h voidmain () (intn; i nti; floats = 0; printf ("Please enter the n value:"); scanf ("% d", & n); for (i = 1; i = n; i + +) s = s +1 * (float) ( 2 * i-1); printf ("S = 1 +1 * 3 + 1 * 5 + ... 1 * (2n-1) of the results:% f * n ", s);)