array and hash problems