Jump to content

Recommended Posts

Posted
class thing 
{ 
 public: 
    int x; 
    int y; 
    thing(int x, int y) { this->x = x; this->y = y; } 
} 
 
thing whatever(int p) 
   { 
    return thing(p, p); 
   } 
 
int main(int argc, char * argv[]) 
{ 
 thing result; 
 result = whatever(0); 
 ... 
} 

 

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...