Garmin interview question

Pretty basic coding interview questions.