Problem with python
Grant Edwards
grant.b.edwards at gmail.com
Sun Sep 5 10:47:05 EDT 2021
On 2021-09-04, Hope Rouselle <hrouselle at jevedi.com> wrote:
> Igor Korot <ikorot01 at gmail.com> writes:
>
>> Hi,
>> Will this syntax work in python 2?
>
> If you say
>
> print(something)
>
> it works in both.
But it doesn't always work the _same_ in both. If you're expecting
some particular output, then one or the other might not won't "work".
> So, stick to this syntax.
Only if you import print_function from __future__ in 2.x
--
Grant
More information about the Python-list
mailing list