Why is there difference between cmd line and .py file?

Steven D'Aprano steve+comp.lang.python at pearwood.info
Wed Jan 6 00:18:30 EST 2016


On Wednesday 06 January 2016 10:25, Thomas 'PointedEars' Lahn wrote:

> Robert wrote:
> 
>> I just wonder that the cmd line function sum may be different from the
>> .py file used. One is numpy package, the other is a general one. Then,
>> how can I further make it clear for this guess?
> 
> Among other things:
> 
> print(sum.__doc__)


Better:

help(sum)

in the interactive shell.


-- 
Steve




More information about the Python-list mailing list