Can you please check the errors in this code as the test cases are not passing


fixed