Added List<Thread> to join the main after the threads run, so that the outputs go after the threads run.