You use the NEW method to define an instance of the new class, and then call methods that the instance inherited from its superclass. To define an instance of the Savings class named "John Smith," and send John Smith the TYPE and NAME= messages to call the related methods, you enter:
newaccount = savings~new |
say newaccount~type |
newaccount~name = "John Smith" |