NeuroEducation

Ahead in the Queue

Difficulty: Medium · Topics: Discrete Mathematics, Combinatorics, Permutations

Five people — Ali, Bartu, Asu, Buse and Can — stand in a ticket queue. Let x be the number of orders in which Ali is somewhere ahead of Bartu, and y the number of orders in which Asu stands somewhere between Buse and Can.

Find x-y.