How to get to a new line in Python Shell?

前端 未结 7 1668
孤独总比滥情好
孤独总比滥情好 2021-02-02 11:20

In IDLE, say i want to write the following in TWO lines:

x = 3

print x**5

but when i type x = 3 and press enter, it executes the assignment. H

相关标签:
7条回答
  • 2021-02-02 11:58

    End lines with ;\:

    >>> x=3;\
    ... print x**5
    243
    >>>
    
    0 讨论(0)
提交回复
热议问题