I'd like to fill / update a div area in index.html with the result from the python function, but I don't know how to do this. I know there are several other questions with a similar topic but I couldn't succeed with them because they were too specific. I'm pulling my hair out over this.

 Would be someone so nice and guide me?   

This is a function in main.py:

```
@app.route('/')

    def index():
        return render_template('index.html')

 @app.route('/stat/')

        def stat():

            a = 2
            b = 10

            return(str(a) + ' is not ' + str(b))

```

this is the index.html:

```
<body>

    <form action="/stat/"> 

    <button type="submit" id="btn1" class="btn btn-primary btn-sm">check stat</button>

    </form>

 <div id="stat_content"></div>

</body>

```