Nuno Hespanhol wrote:
> Hi.
> I have started learning phyton today!
> I was playing around with some large numbers (fibonacci series)
> and noticed that in some large calculations results have an "L" at the
> end of a number.
> Does this L stands for Large? Is there any way to disable this feature,
> so that all numbers are shown?
> 
> Thanks for your time.

"L" means it is "long integer". In the python interpreter, when you do
something like this:

>>> a

it will actually call the __repr__ of a and print it.

>>> print a.__repr__()

while

>>> print a

will call __str__ of a and print it

>>> print a.__str__()

Python 2.x's long integer __repr__ adds an extra L to denote long
integer, however the __str__ does not.
_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to