That happens because the default toString implementation provides such a info (that is object type and address). However, you may override it providing (in
FeedBack
class) your own implementation of the
toString
method. For example
public String toString()
{
String result = String.format("Enrollment No: %d\nName: %s\nFeedback: %s\nSubject: %s\n", enroll, name, feedback, subject);
return result;
}