Kornit Digital interview question

two hours test, checking whats wrong with a code and writing three functions