Here is my code:
classs = input("Class [1, 2 or 3] - ")
if classs =='1':
name = ).read():
print ("True")
break
else:
print ("False")
So basically, I need the program to find the content 'name' in the .txt file and what comes along with it (same line)
If 'Tom' (name) was in the .txt file and 'Tom' was in-putted as the 'name' the program would output True. As the name was found within the .txt file.
My question is how do i output the contents found under name, which will then allow me to use the integers to output an average score.