I have many years of programming experience, but I am a newbie to Ruby. I have started by creating a Contact class that either contains hashes such as Addresses, Phone Numbers, Email Addresses, etc. Alternatively, I am trying to Addresses and the other classes as inheriting from the Contact class.
What I am seeking is feedback on both approaches. For the Hashes in the Contact class, I am looking for a simple code example of initializing and populating the hash.
For using inheritance, what is the syntax to access the “Home Address” of a contact. Person.Address[“Home”}?
Thanks for any help you can provide