Update constructor fucntions for Vehicle and Train
This commit is contained in:
@ -20,7 +20,7 @@ class Train : public Vehicle
|
|||||||
|
|
||||||
Train::Train()
|
Train::Train()
|
||||||
{
|
{
|
||||||
|
std::cout << "Train constructor" << std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Train::beepHorn()
|
void Train::beepHorn()
|
||||||
@ -37,7 +37,7 @@ void Train::beepHorn()
|
|||||||
|
|
||||||
Vehicle::Vehicle() : speed(0.0f)
|
Vehicle::Vehicle() : speed(0.0f)
|
||||||
{
|
{
|
||||||
|
std::cout << "Vehicle constructor" << std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
float Vehicle::getspeed()
|
float Vehicle::getspeed()
|
||||||
|
|||||||
Reference in New Issue
Block a user