print file content python code example Example: python print contents of file f = open("file_name.txt", "r") print(f.read()) f.close()