# 递归与栈

理解递归之前想要理解函数。

只有函数才能递归。

## 函数

关于计算机里的函数

```c
int main() {
    for (int i = 0; i < 100; i++) {
        cout << i << endl;
    }
}
```

数学里的函数

$$y = x^2 + 2x + 1 = (x + 1)^2$$

数学上的函数和计算机里的函数是有区别的，计算机里的函数要多一些东西东西的。


---

# 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://embedded.xym.work/01-ji-suan-shi-shen-me/1_1program_basic/3_algorithm/7-di-gui-yu-zhan.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.
