View Single Post
Old 08-18-2002, 11:17 PM   #7 (permalink)
abc123
bloomberg
 
abc123's Avatar
 
Join Date: Jun 2002
Location: bloomberg
Posts: 263
abc123 is on a distinguished road
Send a message via AIM to abc123 Send a message via Yahoo to abc123
well i dont know what redhead is talking about eliminating the void altogether but basically, as everyone has said, void is for functions that don't return anything


Code:
void setup()
{
  //load things
  name = "bob";
  age = 10;
}
that doesn't need to return anything, so its void, but...

Code:
int getAge()
{
   return age;
}
that implies that something will be returned, hence it is.

void = "i wont return anything";
__________________
-- bloomberg.
abc123 is offline   Reply With Quote