Home > Back-end >  C program to solve
C program to solve

Time:10-05

#include

Int main (int arg c, char * argv [])
{
Int n

Printf (" please enter the first integer: ");
The scanf (" & amp; D, & amp; N);
Printf (" you input integers for & amp; D \ n, n)
"Printf (" behind the integer integer for & amp; D \ n ", n + 1);

return 0;
}
What I use is dev - c + 5.6.1 this why can't afford to have been compiled in the printf (" please enter the first integer: "); Display error when she was here for ~ ~ ~ ~ ~ ~ ~

CodePudding user response:

Uh...
 printf (" please enter the first integer: "); 
The scanf (" & amp; D, & amp; N);
Printf (" you input integers for & amp; D \ n, n)
"

Chinese ";"
Then the lack of;

This kind of problem...

CodePudding user response:

Watch out, the original poster is a novice,
 # include & lt; stdio.h> 

Int main (int arg c, char * argv [])
{
int n;

Printf (" please enter the first integer: ");
The scanf (" % d ", & amp; N);
Printf (" you input integers for % d \ n ", n);
Printf (" behind the integer integer for % d \ n ", n + 1);

return 0;
}

CodePudding user response:

"& amp;" Is the address-of operator, in the scanf (" % d ", & amp; N); Use is right,
"% d" is the output an integer, so the printf (" behind the integer integer for & amp; D \ n ", n + 1); To printf (" behind the integer integer for % d \ n ", n + 1);

CodePudding user response:

The printf in & amp; Changed to %

CodePudding user response:

This questions lz should not come here, to this problem the time far & gt; Reading time, should look up, the heart

CodePudding user response:

This LZ must be a novice, write the code is very meticulous work, pay more attention to details
  • Related