IBM Interview Question

How was the difficulty of this assignment