nested lis comprehesion


Author: yifei / Created: May 30, 2017, 9:17 p.m. / Modified: May 30, 2017, 9:17 p.m. / Edit

[x for li in lists for x in li if x]

can be treated as

[x
    for li in lists
        for x in li
             if x]

评论区