| Показать все ветки Спрятать все ветки Показать все сообщения Спрятать все сообщения |
| Why WA#8? | Alexander Samal | 1741. Монстр общения | 14 апр 2010 13:41 | 8 |
What to do if it doesn't help? Help anybody!!! I have WA8! Give me some helpful tests. Need I use Topological Sort if I use shortest path in DAG; Now I just use Sort by beginning of the edge. Edited by author 02.11.2009 01:59 Edited by author 02.11.2009 01:59 Oh, it was stupid mistake!!! I just increased const INFINITY in the array if distances and got AC. I really hate it when I have to resubmit just because this judge doesn't support "%lld" operator... Very strange, with typedef long long I; I get AC with #define H I(10000000000000000LL) but WA8 with # define H I(1e16) |
| WA Test 18 | JohNY_green | 1433. Тетраэдры | 14 апр 2010 13:10 | 1 |
I got WA at test18, can somebody give some test or hint, please? |
| 2 admins | DK [Samara SAU] | 1768. Кольцевые струны | 14 апр 2010 04:03 | 3 |
2 admins DK [Samara SAU] 11 апр 2010 16:29 It could be proven that for n != 4 there is always 'NO' answer. Is it right for each test? e.g. in test 8 n != 4 and answer is 'YES'. With absolute precision of calculations u will get 'NO' I read your posts very attentievely, but I didn't understand what exactly you mean. What's about test: 5 1 0.5 0.654508, 0.975528 0.0954915, 0.793893 0.0954915, 0.206107 0.654508, 0.0244717 I am sure the answer is YES |
| for pascal only prob1001 | ghostfreak | 1001. Обратный корень | 13 апр 2010 16:46 | 2 |
i've got memory limit on test #3 what can i do??? i use array of int64[1..200000] Edited by author 11.04.2010 19:24 Edited by author 11.04.2010 19:41 ar vici mec ver amovxseni shetanashi maq etyoba shecdoma while not eof do read(n); :( |
| Is there anything speciale in tests 13? | Alexey | 1279. Warehouse | 13 апр 2010 12:58 | 3 |
When I wrote my first version, I had TLE#13. I optimize it - Crash#13. Help me with tests or hints. Please. Thanks. Edited by author 10.05.2006 20:37 I guess in this test one needs to add to the largest section (and N*M is not very small) -- I had a problem with 1e8 sentinel. This test helped me a lot. 2 2 10 1 3 2 4 Output is: 5 |
| help!!WA10 | brian·hbc | 1688. Team.GOV! | 13 апр 2010 11:32 | 1 |
what's wrong? program t1688; var h:array [1..3000] of int64; a,p:int64; n,m:int64; b,i,j:longint; begin readln(a,b); for i:=1 to b do readln(h[i]); for i:=1 to b-1 do for j:=b downto i+1 do begin if h[i]>h[j] then begin p:=h[i]; h[i]:=h[j]; h[j]:=p; end; end; for i:=1 to b do begin m:=m+h[i]; if a*3<m then inc(n); end; if n=0 then writeln('Team.GOV!') else writeln('Free after ',b-n,' times.'); end. Edited by author 16.04.2010 11:37 |
| WA8 | Tomislav Gudlek | 1199. Мышка | 13 апр 2010 00:54 | 2 |
WA8 Tomislav Gudlek 8 апр 2010 21:21 Re: WA8 Mislav Balunović 13 апр 2010 00:54 Does someone here know the reason why so many people fail on test 8? |
| WA#8 | logmax | 1021. Таинство суммы | 12 апр 2010 23:57 | 1 |
WA#8 logmax 12 апр 2010 23:57 problem solved Edited by author 13.04.2010 14:37 Edited by author 13.04.2010 14:37 |
| Why doesn't labs() work? | Avatar | 1767. Дом доктора Ди | 12 апр 2010 22:03 | 2 |
I got WA6 in this case: if (inc1 == inc2) { cout << labs(cr2x - cr1x) + labs(cr2y - cr1y); return; } cout << max(labs(cr2x - cr1x), labs(cr2y - cr1y)); but I got AC in this case: if (inc1 == inc2) { cout << (cr2x - cr1x) + labs(cr2y - cr1y); return; } cout << max(labs(cr2x - cr1x), labs(cr2y - cr1y)); and in this case: if (inc1 == inc2) { cout << labs(cr2x - cr1x) + (cr2y - cr1y); return; } cout << max(labs(cr2x - cr1x), labs(cr2y - cr1y)); and in this: if (inc1 == inc2) { cout << (cr2x - cr1x) + (cr2y - cr1y); return; } cout << max(labs(cr2x - cr1x), labs(cr2y - cr1y)); p.s. cr1x, cr1y, cr2x, cr2y is long long, (cr2x - cr1x)>=0 and (cr2y - cr1y)>=0 always, but why in this case does not labs() work correctly ? Letter 'l' in "labs" stands for "long" = "int" (not "long long"). So in the first case two summands are converted from "long long" to "int" and the summation causes overflow. In the second and the third cases one of the summands has type "long long" so the sum is in type "long long" too. Edited by author 12.04.2010 22:11 |
| I gotttttt ACepted | vadim s | 1025. Демократия в опасности | 12 апр 2010 21:06 | 3 |
You real-true-mega-shguzhii coder ! How you write this program? |
| GREEDY at all | lonelycorn | 1025. Демократия в опасности | 12 апр 2010 21:04 | 2 |
let a[i] stand for the member of party i; sort it to make a[1]<a[2]<...<a[n] for i:=1 to (k+1) div 2 do inc(answer,(a[i]+1) div 2); the answer is sure to be the best one. I have such sing too,but say me how you write this program I don't understood! |
| Hwo know Pascal AC solution? | George Skhirtladze | 1003. Чётность | 12 апр 2010 20:56 | 1 |
|
| WA #6 | Ego | 1767. Дом доктора Ди | 12 апр 2010 20:49 | 3 |
WA #6 Ego 11 апр 2010 19:16 |
| No subject | Nellie | 1083. Факториалы!!! | 12 апр 2010 19:13 | 1 |
Edited by author 12.04.2010 19:19 Edited by author 12.04.2010 19:20 |
| Whats wrong ADMINS? | George Skhirtladze | 1732. Министерство правды | 12 апр 2010 18:56 | 1 |
program ministerstvo; var a,n,i,b,j,k,p,l:longint; s,w,q,r:string; begin readln(s); readln(w); n:=length(s); k:=length(w); i:=1; j:=1; l:=1; p:=1; while i<n do begin if s[i]<>w[j] then begin while s[p]<>w[l] do begin if s[p]=' ' then s[p]:=' ' else s[p]:='_'; p:=p+1; i:=i+1; end; end; if s[i]=w[j] then begin i:=i+1; j:=j+1; l:=j; p:=i; end; end; k:=0; for i:=1 to n do if s[i]<>'_' then k:=k+1; if k<length(w) then writeln('I HAVE FAILED!!!') else begin if w[length(w)]=s[n] then write(s[i]) else begin for i:=1 to n-1 do write(s[i]); end; end; end. |
| Where is my mistake? | Volov_Forever | 1005. Куча камней | 12 апр 2010 16:34 | 7 |
WHERE IS MY MISTAKE??? #include <iostream> #include <cmath> using namespace std; int main () { int a[100000],n,i,s1=0,s2=0,min; cin>>n; for (i=1;i<=n;i++) cin>>a[i]; for (i=1;i<=n;i++) { if (s1>s2) s2+=a[i]; else if (s1==s2) s1+=a[i]; else s1+=a[i]; } min=abs (s1-s2); cout<<min<<endl; return 0; } Try this test 5 10 10 8 4 8 Right answer is 0 Edited by author 20.03.2009 14:09 |
| Bad Tests(admins, don't look haphazardly) | Tural Neymanov | 1005. Куча камней | 12 апр 2010 16:33 | 7 |
8 3 7 9 11 13 18 21 42 my dynamic programming solution isn't really dynamic programming solution, because this test ruined it. facinating is that, when test is written back to front answer is right. answer is 0, my is 2. sorry for my magnificent english. =) Edited by author 11.04.2009 18:41 another test: 6 30 29 13 5 5 3 Edited by author 11.04.2009 18:42 * Tural Neymanov 14 апр 2009 15:00 * Edited by author 14.04.2009 15:00 HEEEY Tural Neymanov 14 апр 2009 15:00 why didn't you check it??? Then, what kind of admins are they, anyway??? Re: HEEEY George Skhirtladze 12 апр 2010 16:33 |
| WA #35 test | Alexander Samal | 1767. Дом доктора Ди | 12 апр 2010 16:25 | 1 |
2 -1 -2 0 0 2 0 -2 answer: 1 |
| WA #3 | Artem Khizha | 1767. Дом доктора Ди | 12 апр 2010 15:30 | 11 |
WA #3 Artem Khizha 11 апр 2010 15:51 Sorry, but get tired of it. Are there any suggestions, what checks test #3? > each street stretches through the whole city either from west to east or from north to south. Do these directions have any influence? I have same problem my code is #include <iostream> #include <math.h> using namespace std; int main() { int x[2],y[2],a[2],b[2]; cin>>x[0]>>x[1]>>y[0]>>y[1]>>a[0]>>a[1]>>b[0]>>b[1]; double e=((y[0]-x[0])*(y[0]-x[0])); double t=((y[1]-x[1])*(y[1]-x[1])); double u=e+t; double qq=sqrt(u); double ww=sqrt(qq); double ee=((b[0]-a[0])*(b[0]-a[0])); double tt=((b[1]-a[1])*(b[1]-a[1])); double uu=ee+tt; double qqq=sqrt(uu); double www=sqrt(qqq); double iga=ceil((www+ww)/2); cout<<iga; return 0; } what to do?help please..... 1 1 5 5 2 2 4 4 output should be 4, i think. your program gives 3. My algorithms is: make 2 rectangles first with points Dr Dee House and St Paul Cathedral second with points Gallery and Museum next find rectangle which is the intersection of the first 2. the result is width + height of the last rectangle. but still WA on test 3 1 1 5 5 2 4 4 2 output should be 2, i think. your algorythm gives 4 yeah, the algorithm is wrong I changed it and now WA on test #6 1) 0 0 6 2 0 0 6 2 == 8 2) 0 0 6 2 0 2 6 0 == 6 3) 0 0 2 6 0 6 2 0 == 6 Re: WA #3 TereshinVS Liceum#165 12 апр 2010 15:30 thank you. now i understand... Edited by author 12.04.2010 15:34 Edited by author 12.04.2010 15:34 |
| HINT | Boleyn Su | 1088. Илья Муромец | 12 апр 2010 14:29 | 1 |
HINT Boleyn Su 12 апр 2010 14:29 HINT: dec(Ep);dec(Dp); //for Pascal Ep--;Dp--; //for C/C++ |