What will this object-oriented program print?
#include <iostream>
#include <string>
using namespace std;
class Vehicle {
public:
string fuel = "none";
};
class MotorizedVehicle : public Vehicle {
public:
string fuel = "fossil";
};
class NextgenMotorizedVehicle : public MotorizedVehicle {
public:
string fuel = "hydrogen";
};
int main() {
MotorizedVehicle aCar;
cout << aCar.fuel;
return 0;
}