fixed the problem for example 3.
added Person class.