First version, using Array
Second version, using Hash