pass : 실행할 코드가 없는 경우
continue : 다음 순번 loop 로 넘어감
for i in list:
if "data" in i:
pass
print(i)
-> i에 "data"가 포함되어도 print(i) 출력됨
for i in list:
if "data" in i:
continue
print(i)
-> 에 "data"가 포함되면 다음 loop가 돌게됨
'python3' 카테고리의 다른 글
[json] pandas dataframe to json file / json file read, write, append (0) | 2020.11.19 |
---|---|
[pandas] dataframe get row value / 데이터 전처리 (0) | 2020.06.01 |
[type] java.math.BigDecimal to integer (0) | 2020.05.12 |
[pandas] columns rename (0) | 2020.05.12 |
[pandas] 행 데이터 가져오기 loc, iloc / get value 특정값 추출 (0) | 2020.05.12 |