I know that if a variable is a word then it is a string. If it has numbers it is a float.
What type of variable would it be if it opens a code. Here is my code:
problem = open('problems.txt')
lines=problem.readlines()
You need to use
type(problem)
Which gives you :
<type 'file'>