开发者

Python: cannot print (execution flow ?)

I am interested in a small python application, which can be downloaded here: https://launchpad.net/treemap

If you run it, like this:

python treemap-basic.py examle-world-population.txt

It works just fine. The problem is that even if I type a print command in the "treemap-basic.py" file:

print "Hello W开发者_StackOverfloworld !" @ treemap-basic.py

I cannot see the message "Hello World !" at the Terminal. Why?


I downloaded this script, and inserted

print "Hello World"

on line 64. When simply trying ./treemap-basic.py on the terminal, you get an IndexError since treemap-basic.py expects a command line argument. When you specify a file to work on:

./treemap-basic examle-world-population.txt

You see a bunch of output in stout. If you scroll up to the top (right below where you first entered the command in the terminal) you should see "Hello World" as the first line of output.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜