Publicis Sapient interview question

Logical questions