943,733 Members | Top Members by Rank

Ad:
  • C++ Discussion Thread
  • Unsolved
  • Views: 436
  • C++ RSS
Sep 14th, 2009
0

Noob as it gets

Expand Post »
Hey, guys. I've decided to learn C++ for fun while we're having some downtime here at work.

I'm using Microsoft Visual C++ and it doesn't explain a couple of bits of basic syntax:

On the line

int main ()

What does "int" stand for? It seems to be used for an integer variable elsewhere. And what are the parentheses for? In case I want to set some parameters?

Thanks!

Tom
Similar Threads
Reputation Points: 10
Solved Threads: 0
Light Poster
Tom Tolleson is offline Offline
39 posts
since Oct 2007
Sep 14th, 2009
0

Re: Noob as it gets

Well , if you have started C++ right now , It would be hard to understand what int main () stands for, Most books explain the code as the place where the execution of the program begins.

And I tend to prefer it to be that way, until you get to "functions" . Once you are pretty much aware about functions , you will see that it all comes into place,
If you have already studied functions suggestion to you would be to consider revising through the book that you are reading and look again into Functions.

For a good reference you could use the basics of functions Here

[EDIT]
AND THEN if you have a doubt, you are always welcome to ask [/Edit]
Last edited by Sky Diploma; Sep 14th, 2009 at 1:44 pm.
Reputation Points: 673
Solved Threads: 125
Practically a Posting Shark
Sky Diploma is offline Offline
818 posts
since Mar 2008
Sep 14th, 2009
0

Re: Noob as it gets

Well , if you have started C++ right now , It would be hard to understand what int main () stands for, Most books explain the code as the place where the execution of the program begins.

And I tend to prefer it to be that way, until you get to "functions" . Once you are pretty much aware about functions , you will see that it all comes into place,
If you have already studied functions suggestion to you would be to consider revising through the book that you are reading and look again into Functions.

For a good reference you could use the basics of functions Here

[EDIT]
AND THEN if you have a doubt, you are always welcome to ask [/Edit]
I'm starting the chapter on functions now! I'm sure I'll have a grip on this by the end of the day.

Thanks so much for your helpful reply!

Tom
Reputation Points: 10
Solved Threads: 0
Light Poster
Tom Tolleson is offline Offline
39 posts
since Oct 2007

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in C++ Forum Timeline: convert given timestamp and timezone to broken-down time
Next Thread in C++ Forum Timeline: help for templates!!!!





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC