I'm making tic-tac-toe in python. I have a board, and each of the squares corresponds to a number (0-8) and to help with win conditions, I have this list:
wins = [[0, 1, 2], [3, 4, 5], [6, 7, 8], [0, 3, 6], [1, 4, 7], [2, 5, 8], [0, 4, 8], [2, 4, 6]]
Whenever one of the players puts down a letter, wherever they placed the letter gets put into a list, so at the end of the game one of their lists might look like this:
player1 = [0, 1, 4, 5, 6]
How do I check if all of the elements of one of the nested lists are in player1 (regardless of order, if possible)?