TEMA

Presentation Error

Matt Ramos preguntado 2 years ago

I have for submissions with PE

At first I thought that my solution didn't print extra spaces, for example word word would have been word word in my solution.

So i changed my solution to take into account that case, but it's still giving PE.

Any idea why is giving me PE??

Este tema fue resuelto y no puede recibir nuevas respuestas.

  • feodorv respondido 2 years ago

    Can you print accidentally two '\n'? One can left from line, second is on printing the answer as "%s\n" or cout << ans << endl.

  • Matt Ramos respondido 2 years ago

    Well it's solved. It was missing a \n i was printing just one line. Thanks for your help.

  • Matt Ramos respondido 2 years ago

    And if the input line ends with a space?

    @feodorv In that case it prints the space.

    Also if the line starts with a space.

  • feodorv respondido 2 years ago

    And if the input line ends with a space?