• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

need help to compile my C program. It keeps telling me i have errors!** new Problem**

Umm, the error messages seem pretty self explanatory...

your main function should be declared

int main()
{
// code here
return 0;
}

<edit>I guess you figured it out 🙂</edit>
 


<< Take "\n" out of all of your scanf calls. >>



Edit: if necessary (it is not), you can put a \n at the beginning of your printf strings.
But the \n at the end of the scanf input string messes you up. Scanf is picky.
 


<< Ok one more thing, how do i get the program to display the comments in the beginning? >>


You can't, unless you printf them out. Comments are only meant for internal use, they don't get into the binary after you compile the code.


🙂atwl
 
Back
Top