Automatically called by Java when printing or concatenation is needed with your object
toString() the class file. e.g. Amy(1/5)print in the main. Output : Amy(1/5)
constructor
used to instantiate (create an instance of) an object
normally use it to initialize the instance variables
use to do any kind of processing that needs to be done when the object is created
no return type
must have the exact same name as the class
Java provides a default constructor that does not do anything except instantiating the object in case no constructor is defined in a class (disappears as soon as any constructor is defined in the class)
main. shows how to call the constructorTwo different constructors