2017.5.3 sort test

作者: LorryZ | 来源:发表于2017-05-16 22:27 被阅读2次

    travel = ['Britain','Germany','America','Swiss','Japan']

    print(travel)

    print(sorted(travel))

    print(travel)

    print(sorted(travel,reverse=True))

    print(travel)

    travel.reverse()

    print(travel)

    travel.reverse()

    print(travel)

    travel.sort()

    print(travel)

    travel.sort(reverse = True)

    print(travel)

    print(travel[-1])

    相关文章

      网友评论

        本文标题:2017.5.3 sort test

        本文链接:https://www.haomeiwen.com/subject/maultxtx.html