python list of dict change dicts id by position in list when moved

Solutions on MaxInterview for python list of dict change dicts id by position in list when moved by the best coders in the world