Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

if else in list comprehension

[<Exp1> if condition else <Exp2> if condition else <Exp3> for <item> in <iterable>]
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #list #comprehension
ADD COMMENT
Topic
Name
8+5 =