getting Wrong answer in HORSES

Need to know where is my code failing

Solution is present at the following location

Each output should be on the new line…

You missed to print a new line after the output.

(1) there is inbuilt sort function available in c++ which you can use instead of writing the whole function

1 Like