added do_first to add tasks to the front of the prerequisite and action queues