IBM interview question

Logic and data structures and algorithms