mirror of https://github.com/python/cpython
Note version added for conditional expressions
This commit is contained in:
parent
e2dd78c760
commit
f9f61b4aa2
|
@ -1039,7 +1039,7 @@ The operator \keyword{not} yields \code{True} if its argument is false,
|
|||
The expression \code{\var{x} if \var{C} else \var{y}} first evaluates
|
||||
\var{C} (\emph{not} \var{x}); if \var{C} is true, \var{x} is evaluated and
|
||||
its value is returned; otherwise, \var{y} is evaluated and its value is
|
||||
returned.
|
||||
returned. \versionadded{2.5}
|
||||
|
||||
The expression \code{\var{x} and \var{y}} first evaluates \var{x}; if
|
||||
\var{x} is false, its value is returned; otherwise, \var{y} is
|
||||
|
|
Loading…
Reference in New Issue