인프런 영문 브랜드 로고
인프런 영문 브랜드 로고

Inflearn Community Q&A

zioya1230999's profile image
zioya1230999

asked

[Renewal] Python Introduction and Basic Crawling Bootcamp [Python, Web, Basic Data Understanding] (Updated)

Python Basics: Getting Naturally Acquainted with Functions by Solving Problems

for문 질문있습니다!

Written on

·

148

0

for ii in range(~~):

구조에서 ii는 별도로 지정하지 않아도 숫자 1부터 시작하게 되는게맞나요?

python웹-크롤링

Answer 1

0

funcoding님의 프로필 이미지
funcoding
Instructor

for ii in range(5): 와 같이 쓰셨을 경우,  ii 는 0부터 4까지, 그래서 0부터 시작하는 것이 맞습니다.

이런 부분은 ii 를 print(ii) 로 반복문 내부에서 출력해보세요. 변수등은 항상 코드에서 출력을 해보시는 습관을 들이셔서, 변수값이 어떻게 변하는지를 보시는 것이 중요합니다.

zioya1230999's profile image
zioya1230999

asked

Ask a question