티스토리 뷰
336x280(권장), 300x250(권장), 250x250, 200x200 크기의 광고 코드만 넣을 수 있습니다.
내부에서 자기자신을 호출하여 반복
>>> def countdown(x):
if x == 0:
print ("GO!")
else:
print(x)
countdown(x - 1)
>>> countdown(10)
10
9
8
7
6
5
4
3
2
1
GO!
'Python' 카테고리의 다른 글
Python, help (0) | 2016.04.21 |
---|---|
Python, Pass (0) | 2016.04.21 |
Python, 함수 lambda (0) | 2016.04.21 |
Python, 함수_인수 (0) | 2016.04.21 |
Python, 함수_스코핑룰 (0) | 2016.04.21 |
댓글
공지사항
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
링크
TAG
- tkinter
- 폼
- Linux
- vba
- fetch join
- highlightbackground
- command
- tkinter command & bind [명령어묶기와 사건묶기] Python
- Python
- 리눅스
- JPA
- checkbutton
- activebackground
- Private
- FetchType
- Java
- activeforeground
- 상수
- disabledforeground
- onetomany
- borderwidth
- Composite Key
- Excel
- apache
- highlightthickness
- 파이썬
- ManyToOne
- Module
- indicatoron
- IdClass
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
글 보관함