Travelling salesman problem

i understand all the video but one thing i not get is how top down approach working mens how can be mask and pos can be same more than once

@Saurabh2771999 it can be same when order of city you already travelled changes.
Let’s say you have 4 cities and now you are visiting 3rd city and you have already visited city 1 and 4. so mask is 1001 and pos is 3.
Now this state can be called twice.

  1. when you visit city in order 1->4->3.
  2. when you visit city in order 4->1->3.