Jan-06-2018, 05:30 PM
This seems to work too, is it correct?
def isValid(word): file = open("AllEnglishWords.txt", "r") if word in file.read(): return True else: return False print(isValid("\n"+word+"\n"))I adjusted the file with two 'enters' at the beginning and the end of the file.