Show all threads Hide all threads Show all messages Hide all messages |
WA18 | tepamid | 1275. Knights of the Round Table | 1 Oct 2021 07:13 | 2 |
WA18 tepamid 18 Mar 2021 19:02 Try this if you have WA18: 10 7 3 0 5 9 2 3 7 3 1 4 4 Re: WA18 Nedyalko Borisov 1 Oct 2021 07:13 The answer is: 12 1 8 + 1 8 + 4 1 + 9 6 + 2 9 - 2 9 - 3 10 - 6 3 - 6 3 - 6 3 - 6 3 - 6 3 - |
What is the test 29? | Carbon | 1275. Knights of the Round Table | 21 Aug 2016 14:52 | 3 |
My solution falls on test 29. I have AC. My calculation of some values was wrong.:( |
TLE27 | kostan3 | 1275. Knights of the Round Table | 8 Oct 2013 20:17 | 1 |
TLE27 kostan3 8 Oct 2013 20:17 TLE27???????????????? как исправить |
Help! Why do I get WA at test 23??? | SPIRiT | 1275. Knights of the Round Table | 11 Jul 2009 00:40 | 5 |
I don't know, what's wrong with my code. Who knows what's the trap? My AC solution gets WA test 29 if I replace `long` with `short int` (short int is 2 bytes, long is 4) P.S. You've got AC, so maybe you'd write what your problem was, to help anyone? Edited by author 04.02.2006 06:51 Okay, I got AC. But I still don't know, what was wrong with test 23. First I tried to solve this problem by solving Hauss equations very accurately. It works very fast, but it didn't pass the 23 test. After that I rewrote the code. Now I solved 'the rings' directly. It's much slower, but it got AC. The hints are: Start with the first knight and put the numbers 1, 1+K,1+2*K,etc. in a buffer, until you reach the first knight again. These knights form a ring, as I call it. They are served by servant in a form of a ring and don't intersect with other knights. So you can check them separately (the problem, therefore, can be separated in few parts). Now, let us denote: X[i] - the number of goblets brought to the i-th and (i+K)-th knight (don't forget, that i+K maybe more that N and use modulus). Therefore we can say that: X[i]+X[i+K]=F-A[i+k], there A[i]- the initial number of goblets near the i-th knight. Also X[i-K]+X[i]=F-A[i], and etc. Therefore you have to solve a system of linear equations, where each equation has two variables (others are zero). This can be optimised very well. If number of knights in the ring is odd, the solving is one. If it's even, you have to minimise it. The result is Sum(|X[i]|). Good luck to you all If you don't understand the solution you can mail me: vdshevch2@mail.ru |
Test this | litaoye | 1275. Knights of the Round Table | 14 Apr 2009 22:42 | 1 |
I got AC! At first,My program got WA on #18, My bug is when N is even number,my answer is not minimum value 6 1 2 0 2 2 2 2 0 answer should be: 2 6 1 + 6 1 + |
Be careful | N.M.Hieu ( DHSP ) | 1275. Knights of the Round Table | 26 Oct 2008 00:48 | 1 |
I got WA test #21 many times before getting AC. I printed the result without noticing that the servant can take goblets from a knight only if he has at least one goblet near him. So you should print all '+' first and then '-'. |
Please give me some tests. | Khramov Egor(9 class) | 1275. Knights of the Round Table | 17 Sep 2007 12:25 | 2 |
4 1 2 1 0 0 1 ans: 3 2 3 + 2 3 + 1 4 + 3 1 0 3 0 0 ans:-1 4 1 8 7 7 9 9 ans: 2 1 2 + 3 4 - 8 3 2 0 0 2 2 2 3 2 1 ans: 8 1 4 + 1 4 + 7 2 + 7 2 + 8 3 + 3 6 - 4 7 - 4 7 - 5 2 4 3 3 2 2 1 ans:-1 |
Was there a rejudge of this problem?(+) | SPIRiT | 1275. Knights of the Round Table | 20 Apr 2007 21:58 | 2 |
I remembmer clearly that when I solved it there were 74 accepts (I was 75-th). After that the number of AC grew to 90. And right now there is just 70 AC's. What happened? You are right. There were several bugs in the old validator in this problem. Because of them authors with incorrect solutions could get AC. I fixed the validator about 1 or 2 monthes ago. Tests were not changed. |
test 3 | Trần Quang Chung | 1275. Knights of the Round Table | 29 Jun 2006 14:39 | 1 |
test 3 Trần Quang Chung 29 Jun 2006 14:39 My prog WA test 3 please post this test or give me somr test!!! |
Who can help me? I got WA on test 5 Who has the test??? Thank you!!! | Dream | 1275. Knights of the Round Table | 21 May 2004 15:18 | 1 |
|