Hi Thijs, welcome to the world of programmers.
As for creating a program from your python code, it will need to be compiled into an executable. This S/O item may help guide you:
Create a single executable from a Python project - Stack Overflow[
^]
Facebook was originally written in PHP, which is an interpreted language; basically compiled as a page is requested by a
Common Gateway Interface (CGI)... and CGIs date back to the early 1990s. Mark had nothing to worry about