python面试如何以相反顺序展示一个文件的内容?

>>> for line in reversed(list(open('Today.txt'))):
print(line.rstrip())
container
itertools

Debugger
This sem’s subjects

Python, C++, Java
HTML, CSS, jQuery, JavaScript

OS, DBMS, DS, ADA

 

本文首发于Python黑洞网,博客园同步更新

 

posted @ 2019-08-26 07:20  python之蝉  阅读(382)  评论(0编辑  收藏  举报