|
|
back to boardWA14? Posted by Xeqlol 22 Oct 2010 18:53 Есть у кого нибудь идеи? Re: WA14? Similar problem. i have WA at the test #14. I can not understand what I have missed Re: WA14? Who has a WA14 try to use this test: 4 4 1 5 1 5 right answer should be: 1 Re: WA14? Posted by Toshka 19 Feb 2012 20:38 program mega; var n, k, p, i, s:integer; a:array[1..100] of integer; begin read(k, n); for i:=1 to n do read(a[i]); for i:=1 to n do if k<a[i] then begin p:=k-a[i]; a[i+1]:=a[i+1]+1; end; writeln(a[n+1]); end. Помогите плиз в чем ошибка! Re: WA14? what do variable p? Edited by author 21.02.2012 13:33 Re: WA14? Posted by Angel 25 Feb 2012 22:49 i have that respons, but actually i didn't pass(( Re: WA14? Тоже ошибка в 14 тесте, для этих условий: 4 4 1 5 1 5 моя программа выдает правильный результат Re: WA14? Нашла ошибку Попробуйте такой тест: 5 3 6 5 7 Edited by author 08.09.2015 19:19 |
|
|