Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

python if condition assignment in one line

variable = value1 if condition.is_met() else value2
 
PREVIOUS NEXT
Tagged: #python #condition #assignment #line
ADD COMMENT
Topic
Name
3+7 =