Block interview question

Basic Algorithms