gepu1991

input()是一种获取用户输入的方法,从标准输入中读入一个字符串,并自动忽略换行符\n。

换行符\n

>>> print(\'a\nb\')
a
b

>>> user_money = input("please input your money:")
please input your money:1 # 1 是我自己输入的
>>> print(user_money)
1

 

分类:

技术点:

相关文章:

  • 2021-06-09
  • 2021-05-18
  • 2021-06-22
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-02-16
  • 2022-12-23
  • 2021-12-04
  • 2021-10-22
  • 2022-12-23
  • 2022-12-23
  • 2021-04-28
相关资源
相似解决方案