Please check if this is correct

hello @haseebshaik00 yes your code is exactly correct but there is just one error in this .
when you are printing the output there you have to dont have to print n but you have to make separate variable count and then increment it and print that count .
i have corrected your code and now it is passing every test case .


please hit like and mark this doubt as resolved if you feel that your doubt is cleared .

Happy Learning !!