python判斷字符串是否爲空

#encoding=utf-8 str="" if str.strip()=="": print("str is null") if not str.strip(): print("str is null") #encoding=utf-8 str="hello" if str.strip()=="": print("str is null") if str.strip()
相關文章
相關標籤/搜索