Home arrow C++ arrow Beginner's Guide to Functions in C++
C++

Beginner's Guide to Functions in C++


Rich is a self-confessed C++ guru! In this article he shows us how functions work in C++ and how to use them in everyday C++programming.

Author Info:
By: Rich C.
Rating: 4 stars4 stars4 stars4 stars4 stars / 213
December 05, 2002
TABLE OF CONTENTS:
  1. · Beginner's Guide to Functions in C++
  2. · A Basic Program
  3. · Using 2 Different Functions
  4. · Functions Calling Other Functions
  5. · Conclusion

print this article
SEARCH DEVARTICLES

TOOLS YOU CAN USE

advertisement
Beginner's Guide to Functions in C++
(Page 1 of 5 )

All C++ programs use functions. The first program you ever wrote in C++ used a function you declared as "Main". Main is called by the computer operating system. Main is usually declared as an integer-returning function, and that is why your programs end when Main returns a '0'. When Main returns a zero, the operating system is told that everything went OK. Please remember that Main is a REQUIRED function in a C++ program, so it must be used. Therefore, your programs must at least use a function called Main!
blog comments powered by Disqus
C++ ARTICLES

- Intel Threading Building Blocks
- Threading Building Blocks with C++
- Video Memory Programming in Text Mode
- More Tricks to Gain Speed in Programming Con...
- Easy and Efficient Programming for Contests
- Preparing For Programming Contests
- Programming Contests: Why Bother?
- Polymorphism in C++
- Overview of Virtual Functions
- Inheritance in C++
- Extending the Basic Streams in C++
- Using Stringstreams in C++
- Custom Stream Manipulation in C++
- General Stream Manipulation in C++
- Serialize Your Class into Streams in C++

Dev Articles Forums 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Weekly Newsletter
 
Developer Updates  
Free Website Content 
Contact Us 
Site Map 
Privacy Policy 
Support 



© 2003-2012 by Developer Shed. All rights reserved. DS Cluster 4 - Follow our Sitemap
Popular Web Development Topics
All Web Development Tutorials