Answer:
public abstract class Vehicle
{
private int id;
public int ID
{
get { return id; }
set { id = value; }
}
private string model;
public string Model
{
get { return model; }
set { model = value; }
}
public abstract string VehicleDetail(int id, string model);
}
public class Car : Vehicle
{
public Car() { }
public Car(int id, string model)
{
ID = id;
Model = model;
}
public override string VehicleDetail(int id, string model)
{
return $"{id} - {model}";
}
}
public class Bus : Vehicle
{
public Bus(int id, string model, string make)
{
ID = id;
Model = model;
Make = make;
}
public string Make { get; set; }
public override string VehicleDetail(int id, string model, string make)
{
return $"{id} - {model}" - {make};
}
}
Explanation:
Answer:
d. X ==2
Explanation:
It is a Boolean Expression so == means equal to.
I had to review my Relational Operators/ Conditional Operators, lol.
Is there a photo we can see?
<span>Speak up more so people don't think you're rude</span>
Answer:
special_num = int(input())
if special_num == -99 or special_num == 0 or special_num == 44:
print('Special number')
else:
print('Not special number')
Explanation:
#get input
special_num = int(input())
#if function to evaluate true or false(aka Boolean)
if special_num == -99 or special_num == 0 or special_num == 44:
#true evaluation
print('Special number')
#false evaluation
print('Not special number')