implemented FCFS and priority scheduling