My code won’t compile at all. It is from the project in the java polymorphism lesson. I changed in the main to Language french = new Language(); but it still won’ work uclass Language {
protected String name;
protected int numSpeakers;
protected String regionsSpoken;
protected String wordOrder;
public Language(String langName, int speakers, String regions, String wdOrder) {
this.name = langName;
this.numSpeakers = speakers;
this.regionsSpoken = regions;
this.wordOrder = wdOrder;
}
public void getInfo() {
System.out.println(this.name + " is spoken by " + this.numSpeakers + " people mainly in " + this.regionsSpoken + “.”);
System.out.println("the language follows the word order: " + this.wordOrder);
}
public static void main(String args) {
Language french = new Language(“French”, 70000000, “France, Switzerland, and Quebec”, “subject-verb-object”);
french.getInfo();
}
}