gpt4 book ai didi

python - 打印空行Python的函数

转载 作者:太空宇宙 更新时间:2023-11-03 11:16:48 24 4
gpt4 key购买 nike

<分区>

我需要创建一个名为 nine_lines 的函数,该函数将使用另一个名为 three_lines 的函数来打印九个空行。

这就是我所拥有的,使用 3.4

  #creating a function within a function
def new_line():
print()
def three_lines():
new_line()
new_line()
new_line()
def nine_lines():
three_lines()
three_lines()
three_lines()
nine_lines

它打印...

  >>>  ================================RESTART================================        
>>>
>>>

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com