Changed everything in order to use processes instead of threads
added feedback from readers