> For the complete documentation index, see [llms.txt](https://theiotlearninginitiative.gitbook.io/embedded-linux/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://theiotlearninginitiative.gitbook.io/embedded-linux/application-development/python.md).

# Python

> Python is a widely used high-level, general-purpose, interpreted, dynamic programming language. Its design philosophy emphasizes code readability, and its syntax allows programmers to express concepts in fewer lines of code than would be possible in languages such as C++ or Java. The language provides constructs intended to enable clear programs on both a small and large scale. \[Wikipedia]\(<https://en.wikipedia.org/wiki/Python_(programming_language>)

* [Five trivial things every python programmer should work with](https://impythonist.wordpress.com/2015/10/11/five-trivial-things-every-python-programmer-should-work-with/)

## Python 3

## Flask

> Flask is a microframework for Python based on Werkzeug, Jinja 2 and good intentions.

* [Flask Homepage](http://flask.pocoo.org/)

```bash
    root@edison:~# apt-get install python-flask
    root@edison:~# pip install Flask
    root@edison:~# nano myflask.py
```

```python
from flask import Flask
app = Flask(__name__)

@app.route("/")
def hello():
    return "Hello World!"

if __name__ == "__main__":
    app.run(host='0.0.0.0', port=5000, debug=True, threaded=True)
```

```bash
    root@edison:~# python myflask.py
    * Running on http://0.0.0.0:5000/ (Press CTRL+C to quit)
    * Restarting with stat
    192.168.1.73 - - [18/Oct/2015 16:34:56] "GET / HTTP/1.1" 200 -
    192.168.1.73 - - [18/Oct/2015 16:34:56] "GET /favicon.ico HTTP/1.1" 404 -
    192.168.1.73 - - [18/Oct/2015 16:34:56] "GET /favicon.ico HTTP/1.1" 404 -
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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://theiotlearninginitiative.gitbook.io/embedded-linux/application-development/python.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.
