OpenSymmetry interview question

They asked me a logic problem