@AsiaCel @nohope. @war_with_myself @asgard
For homework I did this
public class Name {
private String firstName;
private char middleInitial;
private String lastName;
public Name(String firstName, char middleInitial, String lastName) {
this.firstName = firstName;
this.middleInitial = middleInitial;
this.lastName = lastName;
}
public String getFirstName (){
return firstName;
}
public char getMiddleInitial (){
return middleInitial;
}
public String getLastName (){
return lastName;
}
public void sefirstName(String firstName) {
this.firstName = firstName;
}
public void setmiddleInitial(String middleInitial) {
this.middleInitial = middleInitial;
}
public void lastName(String lastName) {
this.lastName = lastName;
}
}
But it’s telling me this
Error emitted from internal testing code. This error is occurring when our internal testing code is trying to call your code. If you see this, it may mean that you have the wrong header for your solution, or a mismatched { } ( ) brace.
You are referring to a name that is not recognized. Perhaps you misspelled it, mis-capitalized it, or forgot to declare it?
cannot find symbol: method setFirstName(String) in variable name of type Name
name.setFirstName(first);
I also still don’t fully understand methods somehow and I think I need to actually practice but the concept as a whole is hard to understand when methods themselves have different concepts in different areas of Java.