Hackerrank Python Basic And Diluted Loss