Beginning question 5 (not 4)

Not working well.
Question 5

Seems to work better. Still I do not think the data structure
I use is optimal.