i get presentation error on test 11 on problem 304 sgu(http://acm.sgu.ru/problem.php?contest=0&problem=304) my biggest problem is i dont know what pe exactly is !! can anyone help ?? this is my code http://paste.ubuntu.com/6489024/
# | User | Rating |
---|---|---|
1 | tourist | 3985 |
2 | jiangly | 3814 |
3 | jqdai0815 | 3682 |
4 | Benq | 3529 |
5 | orzdevinwang | 3526 |
6 | ksun48 | 3517 |
7 | Radewoosh | 3410 |
8 | hos.lyric | 3399 |
9 | ecnerwala | 3392 |
9 | Um_nik | 3392 |
# | User | Contrib. |
---|---|---|
1 | cry | 169 |
2 | maomao90 | 162 |
2 | Um_nik | 162 |
4 | atcoder_official | 161 |
5 | djm03178 | 158 |
6 | -is-this-fft- | 157 |
7 | adamant | 155 |
8 | awoo | 154 |
8 | Dominater069 | 154 |
10 | luogu_official | 150 |
i get presentation error on test 11 on problem 304 sgu(http://acm.sgu.ru/problem.php?contest=0&problem=304) my biggest problem is i dont know what pe exactly is !! can anyone help ?? this is my code http://paste.ubuntu.com/6489024/
Name |
---|
PE means that the output doesn't follow the format. For example, you don't output anything or output "-1" instead of "Impossible" or vice-versa. For this task, you can for example, output 3 on first line, then != 3 numbers on the second.
UPD. Looked in your code, in the task you shold output the indeces of teeth, but in the loop you can output "-1"
ok thanks the -1 is because i wanted to get WA if the problem was with the loop but its still PE :| (i mean at first i submitted the code without the if statement in the loop and it had pe i dont realy know what the problem is but any how thanks :) )
In most of judging systems PE means your output is fine but you don't print it the right way, this usually happens when you print some extra spaces or new-lines, or you don't print them when they are needed. also nic11 mentioned that extra output and similar mistakes can cause this error.
If you have noticed, Codeforces always suggests to use
cin
orcout
or%I64d
instead of%lld
if you are using a 64-bit variable, they might also be the case for this error.thanks :)
As the others says ... Presentation Error means you don't follow the rules of problem for white spaces ( include newlines and spaces ).
In your solution you print one space after each number instead of splitting them with spaces for simplifying,but you have an extra space at the line of numbers which coz presentation error in most judges (codeforces doesn't have PE).
If you add this small change in your code it will be accepted.