看板
[ Python ]
討論串[問題] 關於判斷式的問題...
共 2 篇文章
首頁
上一頁
1
下一頁
尾頁
內容預覽:
補充一下:. .. code:: Python. >>> '1' > 1 # in Python2.x. True. >>> '1' > 1 # in Python3.x. Traceback (most recent call last):. File "<stdin>", line 1, in
(還有61個字)
內容預覽:
各位前輩大家好,. 今晚在寫判斷式時遇到一個問題.... def a(b):. if b>1:. return 'A'. elif b==1:. return 'B'. else:. return 'C'. 請問為什麼我的return都一直回傳A呢?. P.S 抱歉忘了說明,我是利用raw_inpu
(還有307個字)
首頁
上一頁
1
下一頁
尾頁