Dam Digital interview question

Fix10 bugs