| Show all threads Hide all threads Show all messages Hide all messages |
| Зачем прогать? | Volodya | 1283. Dwarf | 28 Oct 2024 22:47 | 1 |
Стал изучать программирование только для того, чтобы кекать с таких заданий |
| WA7 can't find my mistake python | mahachkala wins | 1296. Hyperjump | 28 Oct 2024 07:07 | 1 |
N = int(input()) p = [] maxi = 0 for i in range(N): p.append(int(input())) summi = sum(p) for i in range(N): fsummi = sum(p[i:len(p)-i-1]) if fsummi > maxi and fsummi>summi : maxi = fsummi maxi2 = 0 for i in range(0, N-1): nsummi = sum(p[i::]) jsummi=summi-nsummi if nsummi > jsummi: maxi2 = nsummi else: maxi2 = jsummi if maxi>maxi2: print(maxi) elif summi> maxi and summi>maxi2: print(summi) else: print(maxi2) |
| WA #1 and i couldn't find the mistake! Help, please! | KD | 1003. Parity | 27 Oct 2024 15:41 | 21 |
Вобщем безнадега какая-то Edited by author 25.04.2007 01:26 100 5 5 6 odd 7 8 odd 1 6 even 1 4 odd 7 8 even 3 3 1 1 odd 3 3 odd 1 3 odd 5 4 1 2 even 4 5 even 1 5 odd 3 3 even 10 5 1 2 even 3 4 odd 5 6 even 1 6 even 7 10 odd 20 8 1 9 odd 10 17 odd 18 26 odd 4 5 odd 27 40 even 21 40 odd 1 20 odd 10 20 odd 200 8 1 9 odd 10 17 odd 18 26 odd 4 5 odd 27 40 even 21 40 odd 1 20 odd 10 20 odd -1 Output: 4 3 3 3 2 6 this sample is Wrong!! the right output is: 4 3 3 3 6 6 It used me 3 hours time to debug it..! Final..I find ,,this sample is wrong!! Could you please tell me how to get the datas? Edited by author 23.10.2008 15:28 Edited by author 23.10.2008 15:28 The original output for the test sequence (as posted by pperm) is correct. The last two tests are identical except for the lenght of the 0/1 sequence, which the third question in the 5th test violates, thus giving 2 as the correct answer. I don't know if this is an issue tested by The Judge though ^^ There is nobody wrong ... Because the problem in "18 26 odd" at the fifth test is that 26>20(the length of the sequence) ... But the description of the problem doesn't say anything about this situation , and also there no data like this ... So I doubt that we can use the length of the sequence to do what -_-!!! this sample is Wrong!! the right output is: 4 3 3 3 6 6 It used me 3 hours time to debug it..! Final..I find ,,this sample is wrong!! you are Wrong!! the right output is: 4 3 3 3 2 6 correct answer for the test 3 3 1 1 odd 3 3 odd 1 3 odd is 0, because interval with zero length contains 0 (even) ones :) correct answer for the test 3 3 1 1 odd 3 3 odd 1 3 odd is 0, because interval with zero length contains 0 (even) ones :) This is not correct. The range from 1 to 1 includes one digit at position 1. 100 5 5 6 odd 7 8 odd 1 6 even 1 4 odd 7 8 even for the above input I don't understand why the output should be 4. if 5 6 is odd and 1 6 is even, 1 4 is even, isn't it? No, 1 4 must be odd, because 1 4 + 5 6 = 1 6 or in other words odd + odd = even :) thnx its helpfull.i got ac. all tests passed, still getting wrong answer... it's super old but still I hope to get something i have read all the procedure. but i could not get which file shoul i have to submit for solution plz help me. i will be very thankful to you. Yes, it is just something strange. My program passes all the mentioned tests perfectly. I took in the accounts every remarks mentioned in this forum and still I get WA1. I'm in the same boat. all tests listed here are passing. but still got the WA1. anyone knows how can i get hold of the tests OJ is using? or at least get the feedbacks on the specific failing test case? Altoids, maybe we should try this test (answer -> 4): 12 6 1 2 even 1 1 even 3 4 odd 5 6 even 1 6 even 7 10 odd -1 |
| hehe | ~'Yamca`~ | 1520. Empire Strikes Back | 26 Oct 2024 00:42 | 1 |
hehe ~'Yamca`~ 26 Oct 2024 00:42 btw, random work, but that not just Monte-Carlo |
| WA 3 too... | Combatcook | 1156. Two Rounds | 24 Oct 2024 16:32 | 4 |
Many people has already written about it, but... I really don't understand why I get WA. My program pass all tests here. Please, help to find bug. -- Edited by author 29.07.2016 15:52 Contact me and maybe i'll have some suggestions to help you out~ Edited by author 26.07.2016 17:05 Try 17 29 1 2 2 3 3 4 4 5 5 6 5 7 5 8 5 9 10 11 11 12 12 13 13 14 13 15 13 16 13 17 13 18 19 20 20 21 20 22 20 23 20 24 25 26 26 27 26 28 26 29 30 31 31 32 31 33 31 34 Ans: not "IMPOSSIBLE" |
| random tests | ~'Yamca`~ | 1733. Forgotten Technology | 23 Oct 2024 20:17 | 1 |
0 0 10 0 10 10 0 10 10 10 11 0 -10 Ans: 11.3731475899 0 0 10 0 10 10 0 10 10 10 10 -10 -10 Ans: 22.3606797750 Edited by author 23.10.2024 20:18 |
| easy, but clay | ~'Yamca`~ | 1733. Forgotten Technology | 23 Oct 2024 20:13 | 1 |
|
| Please help me.I got TLE on #4. | EllinY | 1658. Sum of Digits | 22 Oct 2024 17:33 | 1 |
I used dp[901][8101] for dynamic programming,but I got TLE.Can anyone give me some hints? Edited by author 22.10.2024 17:34 |
| code on 1475. Курочка-Ряба | sergo | | 20 Oct 2024 02:39 | 1 |
Post the code for this task, or what is wrong in my code? import math from decimal import Decimal, getcontext, ROUND_CEILING getcontext().prec = 210 for _ in range(int(input())): H, l, h = map(int, input().split()) H = Decimal(str(H)) l = Decimal(str(l)) h = Decimal(str(h)) a = Decimal(str(math.sin(math.atan(H / l)))) d = Decimal("4") * h * a g = Decimal(((H * H) + (l * l)) ** Decimal("0.5")) lm = Decimal("0") rm = Decimal("1e200") for i in range(700): mid = (lm + rm) / Decimal("2") if (d * (mid + 1) * mid) <= g: lm = mid else: rm = mid print(rm.quantize(Decimal('1'), rounding=ROUND_CEILING)) Edited by author 20.10.2024 02:41 |
| RE2 in Rust | Yury_Semenov | 1269. Obscene Words Filter | 16 Oct 2024 20:41 | 1 |
In the statement, "any symbol" means NOT any valid ASCII char, but any byte, including those with codes 128..255. Common methods to read text in Rust, including stdin().read_line, expect valid UTF-8 and therefore crash on test 2 where bytes 128..255 are present. I got AC with this: let mut reader = BufReader::new(stdin()); let mut s = Vec::new(); reader.read_until(10, &mut s).unwrap(); |
| Some test cases [AC] | Lucas Negri | 1389. Roadworks | 16 Oct 2024 18:56 | 5 |
Nevermind. Solved. I've detected my error with this input: 11 10 1 2 1 3 2 4 2 5 3 6 3 7 4 8 5 9 6 10 7 11 5 roads can be blocked. Edited by author 29.08.2011 22:33 The answer is: 5 1 2 4 8 5 9 3 6 7 11 Thank you very much! I tested your case and detected an error too. After fixing a bug, I got an AC. And that's mostly because of you! Thanks for pointing out this test case. It helped me as well. |
| Test 30 | ilyaodin | 2078. Bowling game | 15 Oct 2024 22:48 | 1 |
Wrong answer, test 30. Don't now what to do |
| For WA 15 and 25 | Hououin`~`Kyouma | 1182. Team Them Up! | 15 Oct 2024 16:48 | 1 |
WA 15: "Teams are as close in their sizes as possible." It doesn't mean that the size of one of the commands must be exactly n//2. Wa 25: "Every team has at least one member" Edited by author 15.10.2024 20:07 |
| a little hint | LeTim | 1952. To Kill the Dragon | 14 Oct 2024 19:48 | 1 |
use dynamic programming by subsets, one mask in DP state for one breath in a row and two masks in DP state for two breaths in a row, time complexity ~O(k * (n+m)^2 * 4^(n+m)) |
| WA18 | Nisarg Shah | 1608. Lucky Tickets 2008 | 13 Oct 2024 11:52 | 2 |
WA18 Nisarg Shah 15 Dec 2008 10:49 I had WA7....corrected one error but now getting WA18...Mods please give me 18th test case... Thanks... Edited by author 09.01.2009 13:12 idk why you get error, but i get ac on this task by deleting my whole code and write it again, i'm try to dont use my old ideas in new code |
| TO ADMINS. Weak tests. | AndreyPikas [Yaroslavl SU] | 1415. Mobile Life | 12 Oct 2024 21:13 | 9 |
Some of my AC solutions don't pass this test: 3 9999 10000 1 A -9990 9999 999 B -10000 9999 1000 C 1 9999 10000 -10000 9998 Right answer: Power on. CELL_ID:A, SIGNAL_LEVEL:VIOLET Signal changed. SIGNAL_LEVEL:INDIGO Signal changed. SIGNAL_LEVEL:BLUE Signal changed. SIGNAL_LEVEL:GREEN Signal changed. SIGNAL_LEVEL:YELLOW Signal changed. SIGNAL_LEVEL:ORANGE Signal changed. SIGNAL_LEVEL:RED Cell changed. CELL_ID:C, SIGNAL_LEVEL:ORANGE Signal changed. SIGNAL_LEVEL:YELLOW Signal changed. SIGNAL_LEVEL:GREEN Signal changed. SIGNAL_LEVEL:BLUE Signal changed. SIGNAL_LEVEL:INDIGO Signal changed. SIGNAL_LEVEL:VIOLET Edited by author 05.11.2014 21:55 Edited by author 05.11.2014 21:56 Add this test too. AC code don't pass it. 3 -10000 9999 1000 A 9999 9999 1000 B -9999 9999 1000 C 1 -10000 9998 9999 10000 Right answer: Power on. CELL_ID:A, SIGNAL_LEVEL:VIOLET Signal changed. SIGNAL_LEVEL:INDIGO Signal changed. SIGNAL_LEVEL:BLUE Signal changed. SIGNAL_LEVEL:GREEN Signal changed. SIGNAL_LEVEL:YELLOW Signal changed. SIGNAL_LEVEL:ORANGE Signal changed. SIGNAL_LEVEL:RED Cell changed. CELL_ID:C, SIGNAL_LEVEL:ORANGE Signal changed. SIGNAL_LEVEL:RED Cell changed. CELL_ID:B, SIGNAL_LEVEL:ORANGE Signal changed. SIGNAL_LEVEL:YELLOW Signal changed. SIGNAL_LEVEL:GREEN Signal changed. SIGNAL_LEVEL:BLUE Signal changed. SIGNAL_LEVEL:INDIGO Signal changed. SIGNAL_LEVEL:VIOLET Nice tests! Suppose, if they (and their modifications) are added, many authors will lose AC (because long double accuracy not enough to pass these tests). Also it is quite difficult to implement long arithmetic solution here and pass the TimeLimit. The task will be Hard* instead of Hard. Edited by author 12.10.2024 21:14 Edited by author 12.10.2024 21:15 |
| WA21 | Yury_Semenov | 2064. Caterpillars | 10 Oct 2024 14:57 | 1 |
WA21 Yury_Semenov 10 Oct 2024 14:57 input: 2 1 600000 1 600001 output: 599999 |
| Smallest program possible (+) | Vedernikoff 'Goryinyich' Sergey (HSE: АОП) | 2028. URCAPL, Episode 2 | 8 Oct 2024 05:45 | 4 |
The problem is not that difficult, therefore for me the most interesting question is the smallest program possible to write for this problem. Let's define the size of the program as H x W in your solution. Mine is 6 x 8. Who's smaller? =) I've constructed 5 x 6 shortly after reading the prob, trying to do better in the next several hours but failed. |
| Hint | andreyDagger`~ | 1758. Bald Spot Revisited 2 | 7 Oct 2024 02:40 | 1 |
Hint andreyDagger`~ 7 Oct 2024 02:40 For big tests (at least for n >= 44, but may be works for smaller n's) you can assume that firstt 4 numbers are 33 11 22 44 Edited by author 07.10.2024 02:40 |
| Why I have WA#10? | Марьин | 1489. Points on a Parallelepiped | 6 Oct 2024 21:48 | 2 |
Why I have WA#10? I can't think test to get wrong answer. PLS help me Next my code: #include <iostream> #include <iomanip> #include <cmath> using namespace std; int main() { double a, b, c, x, y, x2, y2; double X, Y, Z, X2, Y2, Z2; double result = 0; bool bflag = true; cin >> a >> b >> c; for (int i=0; i < 2; i++) { cin >> x >> y; if (x < c) { X = 0; Y = y - b - c; Z = x; } else if (x > c + a) { X = a; Y = y - b - c; Z = 2 * c + a - x; } else { if (y <= b) { X = x - c; Y = b - y; Z = 0; } else if (y <= b + c) { X = x - c; Y = 0; Z = y - b; } else if (y <= b) { X = x - c; Y = y - b - c; Z = c; } else { X = x - c; Y = b; Z = 2 * b + 2 * c - y; } } if (bflag) { x2 = x; y2 = y; X2 = X; Y2 = Y; Z2 = Z; bflag = false; } } //cout << X << ' ' << Y << ' ' << Z << ' ' << X2 << ' ' << Y2 << ' ' << Z2; это типа отладка X2 -= X; Y2 -= Y; Z2 -= Z; result = sqrt(X2 * X2 + Y2 * Y2 + Z2 * Z2); if (result < 1.E-8) cout << fixed << setprecision(6) << 0; else cout << fixed << setprecision(6) << result; return 0; } Sorry, I'm find mistake now, it's a one wrong if in my code, thk all to find this |