View Single Post
Old Sep 4th, 2005, 3:32 AM   #3
bl00dninja
Programming Guru
 
bl00dninja's Avatar
 
Join Date: Oct 2004
Location: namespace std
Posts: 1,246
Rep Power: 5 bl00dninja is on a distinguished road
the prototype gives the return type, the name of the function, and the types of the various parameters that are passed to the function. it's just a template for the program to use to plug in your values to return a value. it doesn't say what the function does, just how to start it up.

int function(int x, int y)

is a function called function that takes two integer parameters...x and y, and then returns an integer. it could be adding them, multiplying them, or plugging them into a complicated physics function that outputs anything (as long as it's an integer).
__________________
i put on my robe and wizard hat...

Have you ever heard of Plato, Aristotle, Socrates?...Morons.
bl00dninja is offline   Reply With Quote