# double back-slash for window's nonsense. location_of_files = 'C:UsersHDesktopIntermediate Python' file_name = 'example.txt' with open(os.path.join(location_of_files, file_name)) as f: print(f.read())