返回列表 發帖

變數宣告與基本輸出 (一)

本帖最後由 tonyh 於 2019-2-2 10:36 編輯

  1. a=123
  2. b=456
  3. print(a,"python",b)
  4. print(a,"python",b,sep="~")
  5. print(a,"python",b,sep="~",end="!!!\n")
  6. print(str(a)+"~python~"+str(b)+"!!!")
複製代碼

  1. a=123
  2. b=456

  3. print(a,'python',b)
  4. print(a,'python',b,sep="~")
  5. print(a,'python',b,sep="~",end="!!!\n")                       
  6. print(str(a)+"~python~"+str(b)+"!!!")
複製代碼

TOP

  1. a=123
  2. b=456

  3. print(a,"python",b)
  4. print(a,"python",b,sep="~")
  5. print(a,"python",b,sep="~",end="!!!\n")
  6. print(str(a)+"~python~"+str(b)+"!!!")
複製代碼

TOP

  1. a=123
  2. b=456
  3. print(a,"python",b)
  4. print(a,"python",b,sep="~")
  5. print(a,"python",b,sep="~",end="!!!\n")
  6. print(str(a)+"python"+str(b)+"!!!\n")
複製代碼

TOP

  1. a=123
  2. b=456
  3. print(a,"Python"b)
  4. print(a,"Python"b,sep="~"
  5. print(a,"Python"b,sep="~",end="!!!\n"
  6.       )      
複製代碼

TOP

返回列表