add waitTime recording to fcfs, fix algorithm for sjf