Make a toString method and customize the way you want to build your string.
An example of this can be the following
public String toString() {
String s = "";
`//building the string you want to return like so 's = //How you want it. '`
return s;
}
1
solved Instances: How to I return multiple parentheses like shown in the example?