Is there a way to map multiple values to the same 'person' without creating objects for them each time.
I.E I have a class called Person and Ill need to continuously add to it information like the type of car this person owns (more than one car). I want to be able to add new persons and new cars associated to THAT person.
I need the whole system to be done via terminal so eliminating the need to do the following in the main class for each person.
Person John = new Person();
ALL WITHOUT USING DATABASES. How can I do this?