SJF is now functioning properly
Adding some comments