單項(xiàng)選擇題

在Python中,如何使用條件表達(dá)式(三元運(yùn)算符)?()

A.x if condition else y
B.condition ?x :y
C.if condition:x else:y
D.condition then x else y

微信掃碼免費(fèi)搜題