def task():
print("Executing our Task on Process {}".format(os.getpid()))
def main():
executor = ProcessPoolExecutor(max_workers=3)
task1 = executor.submit(task)
task2 = executor.submit(task)
if __name__ == '__main__':
main()
So i saw this program from this website : https://tutorialedge.net/python/concurrency/python-processpoolexecutor-tutorial/
And i was just wondering if you can have multiple functions under task. Like is process pool only supposed to do one task? Because i have a program that has a function for every task, and wondering how i could convert it to a process pool executor.
Any help would be appreciated. Thank you