public class Dinglemouse {
private String firstName;
private String lastName;
public Dinglemouse(String firstName, String lastName){
this.firstName = firstName;
this.lastName = lastName;
}
public String getFullName() {
if(!firstName.equals("") && !lastName.equals("")){
return this.firstName + " " + this.lastName;
}
if(firstName.equals("") && lastName.equals("")){
return "";
}
return firstName.equals("") ? lastName : firstName;
}
}