Home > Back-end > The great god, help me, look at this problem
The great god, help me, look at this problem
Time:09-16
I waste solution:
Title:
Why don't you can do it? Dear bosses, help!!!! Thank you
CodePudding user response:
The parameters of the printf wrong Change Printf (" %. 6 lf ", sum);//note that sum outside the quotation marks
CodePudding user response:
No, I tried, there is wrong? #include using namespace std; Int main () { int n; Cin> n; Double sum=0; for(int i=1; i<=n; I++) sum +=1.0/I; Printf (" %. 6 lf ", sum); return 0; } Twice, and then have a look
CodePudding user response:
And what's wrong???
CodePudding user response:
I also want to know Is no good!
CodePudding user response:
Passing a doubt yourself to find a way to write a tracking display, to eliminate problems,