Ask coding questions

← Back to all posts
HTML question
112596

How could I have an HTML server running via Python, and at the same time in the backend running a separate code and putting the output into the shell?

Answered by Coder100 [earned 5 cycles]
View Answer
Voters
112596
Comments
hotnewtop
Coder100

Python already does that, try this:

if you want to have 2 programs run simultaneously try using the threading librarry

https://docs.python.org/3/library/threading.html

ruiwenge2
ch1ck3n

you can use flask??? and just do render_template('index.html') and you can also do print('hi') at the same time