# 반복문 (무한 반복) - 반복

### 코드

```
반복
    {반복할 코드}
```

***

### 설명

<mark style="color:purple;">`반복문`</mark>은 원하는 코드를 여러 번 반복해서 실행할 수 있게 하는 코드예요.

***

### 주의사항

* 현재 무한 반복은 호랑에듀 서비스에서 제대로 작동하지 않아요. 코드 실행 시 웹사이트가 멈춘 것처럼 보일 수 있어요.
  * 조건문과 <mark style="color:purple;">`반복 그만`</mark>을 함께 사용해서 문제가 발생하지 않도록 사용해 주세요.

***

### 파이썬 대응 코드

{% code title="반복" %}

```
while True:
    # 반복할 코드
```

{% endcode %}

{% code title="반복 그만" %}

```
break
```

{% endcode %}

***

### 예시

{% code title="예시 코드" %}

```
반복
    "반가워!" 보여주기  # [문자열과 변수를 출력하는 것으로, 반복문과 무관합니다]
```

{% endcode %}

{% code title="예시 코드의 출력" %}

```
반가워!
반가워!
반가워!
반가워!
반가워!
반가워!
반가워!
반가워!
반가워!
반가워!
... (무한 반복)
```

{% endcode %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://codebook.horang.it/readme/010.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
