Cyquent interview question

Some logical questions.