r/learnpython • • Feb 29 '20

Actually used python today

I've been learning python for about a month now. I started with automate the boring stuff like so many others have. Since then I have made some small games to practice. I am currently working on a hangman game and needed a list of words to use. I found a list of words and copied the whole thing to a .text file but it came with extra stuff I didn't need. So instead of manually deleting everything I didn't need I made a python script to do it for me. GREATEST FEELING EVER.

393 Upvotes

63 comments sorted by

View all comments

7

u/floridaturtles Feb 29 '20

Could you please share the code? I’m a very very beginner and I have no idea how you could code that

2

u/dstnmyrs Mar 01 '20

https://pastebin.com/bGMM9jAH

Probably not the most efficient way of doing it but it worked and it took me only 3 minutes to write. This is the script for 5 letter words BTW.