Amazon interview question

Introduction and one coding question