作者huggie (huggie)
看板Python
标题[问题] Expression vs. statement
时间Fri Jan 5 16:25:18 2007
什麽是 expression, 什麽是 statement?
应该有分这两种, 写了很久的python了 还是没弄懂
http://norvig.com/python-iaq.html
Java and C++ have the ternary conditional operator (test ? result :
alternative). Python has resisted this, but in the upcoming Python 2.5 it
will allow expressions of the form (result if test else alternative). This
undermines Python's clear distinction between expressions and statements, but
it is a compromise that many people have asked for.
"distinction between expression and statements" 不懂他什麽意思
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 140.129.160.67