In problems like the 15 Tile Problem or Larry's Array problem, we use inversions in the array as a method to solve.
But what's the principle behind this method and how do I know when to use inversions?
Computer Science Stack Exchange is a question and answer site for students, researchers and practitioners of computer science. It only takes a minute to sign up.
Sign up to join this communityIn problems like the 15 Tile Problem or Larry's Array problem, we use inversions in the array as a method to solve.
But what's the principle behind this method and how do I know when to use inversions?