find critical path nodes and slack nodes