本文共 219 字,大约阅读时间需要 1 分钟。
1、print函数用法
print("你好吗?") print("hello") |
注意:在括号内使用“ ”或‘ ’将字符串组合起来。
print("你好吗?",end="") print("hello") |
注意:这里的end=“ ”函数用来不使用换行使用。结果输出如下
你好吗?hello |
2、print打印输出多个内容
print("大哥","大哥","你好吗?") |
注意:使用“,”分割输出多个内容,输出结果如下
大哥 大哥 你好吗? |
转载地址:http://aduti.baihongyu.com/