Day 7 was spend building a hangman game. This needed some lists to be defined and importing lists from other files. I changed the example up a bit after I found that with enumerate(var) you can get the index of a list for a for loop. The game itself can be played here: https://repl.it/@Magneet/Day-7-Hangman-5-Start#main.py
for index, var in enumerate(list):
with this it was easier to determinate the right placement of the correct letters.
And that was Day 7 of my #100daysofcode Challenge with @yu_angela's 100 days of #python course. Today I create a hangman game that I implemented a bit differently (I also check if a letter was already used if it was wrong) play it here: https://t.co/1sEBtK8REB
— Wouter Kursten (@Magneet_nl) January 10, 2021
I also found someone else who is in exact the same stage as I am doing the 100 days of python course:
https://twitter.com/nik__l/status/1348226464051720193
Not a lot of notes:
var_name = [] defines list for index, var_name in enumerate(other_var): gives both the var you want and the index where it is placed import from other_file imports lists from other py files