At a champions league draw, teams have been grouped into poolsof five (5) each; every team in
Question:
At a champions league draw, teams have been grouped into poolsof five (5) each; every team in the group is connected to anotherteam in its pool in a bilateral manner i.e. a team has apredecessor team connects to it and a successor called its relayteam that it connects to. At a given instance, a FIFA officialcomes and picks any team (P) from a pool, a computer program thenfinds the relay team (R) of the team which was picked by theofficial, removes it from the pool and places it into a group. Therelay team for team R then becomes the relay team for team P. If atany time there remains only one team in the pool, then there is noneed for an official to pick; the program simply takes that teamand places it at the group. Choose an appropriate data structure torepresent this scenario and write a python code of the program