OK...stumped! PS5, is_valid_word: take a look please, I'm baffled. http://codepad.org/FfxIEyAY It doesn't want to compare the word 'eel' or 'ray' which are in variable hand1. Then I randomly tried 'word' and it passed the "word test". Please tell me what's going on
if i use the compiler(interpreter).... >>> 'eel' in word_list True wtf?
Ok...so 'word' works simply because it's reading word_list as a string comprised of 'C:\\Python27\\Doc\\words.txt'. just as '\\Pyt' is also in this string. So clearly my variable link to the text file is inadequate....still I don't know the difference as it loads the words when I restart the shell
From assignments, download ps5.py. In ps5.py you will find the load_words function. is_valid_word will take thee arguments: word, hand, and word_list. word_list is produced by load_words
Did you get your code working?
thats much prettier than my version, but mine works too!
post it kiddo
Ok, but I warned you... it isn't as pretty... lol http://codepad.org/zsalgxPh
looks like it works and you're using the in operator so looks good to me
Join our real-time social learning platform and learn together with your friends!