Feb-18-2019, 06:01 PM
Just glancing at the code, I would say don't eval the input, that will just cause name errors. Also, on line 5, you are comparing one character of guessword to the whole of userinput, so I doubt that ever works correctly. Finally, note that maskString is twice as long as guessword. So you can't use indexes on that the way you are using indexes on the other words.
That brings me to something that is bad coding practice, although it may not be preventing you code from working. You should iterate over the strings, not the indexes of the strings, as shown here.
That brings me to something that is bad coding practice, although it may not be preventing you code from working. You should iterate over the strings, not the indexes of the strings, as shown here.
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures