14
Jan
Jan
Hi I was wondering how would you do this type of a class diagram because i have no idea how to create a class diagram that represents a Vehicle Class pls someone help me
Answer:
in C you can do as
class vehicle
{
private:
int wheels;
int engine;
public:
void getvehicle()
{
}
void showvehicle()
{
}
}
class car : public vehicle
{
private:
char model[10];
int year;
char company[20];
public:
functions for input and outputs
}
class truck:public vehicle
{
char model[10];
int year;
char company[20];
public:
functions for input and outputs
}
};
and so on …
Book Mark it-> del.icio.us | Reddit | Slashdot | Digg | Facebook | Technorati | Google | StumbleUpon | Window Live | Tailrank | Furl | Netscape | Yahoo | BlinkListTags: Class, diagrams, represents, Vehicle
This entry was posted
on Monday, January 14th, 2008 at 10:15 pm and is filed under Programming.
You can follow any responses to this entry through the RSS 2.0 feed.
You can leave a response, or TrackBack URI from your own site.