adding multithreading to 2_4