Your teacher was correct insofar as there is no such thing as a "safe" file.............

Other than that, she is wrong by being too generalistic. Specific viruses will attack specific file types.

Also they may attach (append or prepend), insert, or overwrite.

If you convert a file such that it can be opened with a programming text editor, you should be safe.

Also, have a file(executable) monitor and a registry protector.