摘要: python if not 判断是否为None的情况 if not x if x is None if not x is None if x is not None`是最好的写法,清晰,不会出现错误,以后坚持使用这种写法。 使用if not x这种写法的前提是:必须清楚x等于None, False, 阅读全文
posted @ 2017-12-02 23:39 zxf123 阅读(250) 评论(0) 推荐(0) 编辑