【PythonChallenge】Level 5

题目主要找发声类似于Peak Hell的Python模块,查了一下手册pickle已经是最像的了。看了一下源代码,发现panner.p。如同发现了新大陆,拷贝内容。使用pickle解答。答案为channel。程序如下:

import pickle

filein = open("E:\\Python\\data", "rb")

lst = pickle.load(filein)
print(type(lst))    # Find It is a list, You'd better saw the content first.

string = ""

for li in lst:
    for ch, num in li:
        string += ch * num;
    string += "\n"

print(string)
filein.close()

程序运行如图所示:

 

posted on 2014-02-25 21:02  Bombe  阅读(151)  评论(0编辑  收藏  举报

导航