How to post Python code



  • You should format code snippets using Markdown syntax using triple backticks (```), like this:

    ```python
    for i in this.is_python(code):
        print("i =", i)
    ```
    

    Which will result in nice looking Python code:

    for i in this.is_python(code):
        print("i =", i)
    

    It is strongly advised to use Python 3 syntax.

    Images can be included in your post easily, by dragging them onto the edit area. Pasting an image from the clipboard also works.


Log in to reply