Code of this question

i wrote the code and it is giving correct output then why is it not accepting

Please share the link of the question as well as your code.