Search found 584 matches

by Krzysztof Duleba
Wed Aug 30, 2006 10:49 pm
Forum: C++
Topic: vector<string> MLE ~50MB
Replies: 1
Views: 1572

Re: vector<string> MLE ~50MB

In all problems where i try to use this i get Memory Limit Exceeded. I clear vector for every next case, but no effect. I'm used to get 49632 kilobytes (as tried deque instead were ~33MB) in every problem when i'm using this combo, even if problem description guarantees only up 6MB (100 strings * 6...
by Krzysztof Duleba
Wed Aug 30, 2006 10:39 pm
Forum: Bugs and suggestions
Topic: Author ranks by country?
Replies: 3
Views: 1783

Felix Halim has a very nice proxy that does that, and much more:
http://felix-halim.net/
by Krzysztof Duleba
Sun Aug 27, 2006 11:00 pm
Forum: Volume 110 (11000-11099)
Topic: 11072 - Points
Replies: 24
Views: 13848

StatujaLeha wrote:What algorithm did you use to make convex hull? I used Graham's scan, but it too slow.
Funny you say so - I used Graham's scan too.
by Krzysztof Duleba
Fri Aug 25, 2006 8:23 am
Forum: Volume 110 (11000-11099)
Topic: 11041 - Quarter-Finals with Brazil!? No!!!
Replies: 10
Views: 6966

Yes, that's correct (the proof is not dificult, too), except that the second part is not trivial.
by Krzysztof Duleba
Tue Aug 15, 2006 9:47 am
Forum: C++
Topic: something strange about sizeof struct ?
Replies: 2
Views: 1943

Have you tried using Google? Hint: "sizeof struct".
by Krzysztof Duleba
Mon Aug 14, 2006 6:48 am
Forum: Volume 110 (11000-11099)
Topic: 11073 - Euler's Totient Function
Replies: 20
Views: 6735

I got 19639 outputs for the input 583925760 Can someone tell me is it right? Same here. FAQ - I don't know your algorithm, but map is rather slow. All I use here are 3 arrays (2 for caching primes, 1 for final result) and a recursive function with nice property of generating only correct answers an...
by Krzysztof Duleba
Sun Aug 13, 2006 2:11 am
Forum: Volume 100 (10000-10099)
Topic: 10065 - Useless Tile Packers
Replies: 22
Views: 5953

This is a very cool code, removing pretty much everything completely changes how the compiler behaves, so when I initially refactored it to make it more readable I accidentally made it work :-) g++ 2.95 is not perfect, nor is it's implemention of templates and __typeof, especially on literals. It se...
by Krzysztof Duleba
Sun Aug 13, 2006 1:25 am
Forum: Volume 100 (10000-10099)
Topic: 10065 - Useless Tile Packers
Replies: 22
Views: 5953

Internal compiler error, nothing to see here folks, move along.

Seriously, change typedef pair<int,int> PII to a define or don't use it at all in definition of P if you want to avoid this problem with g++ 2.95.
by Krzysztof Duleba
Sat Aug 12, 2006 2:07 am
Forum: C++
Topic: compile error, why?
Replies: 9
Views: 3295

I would go with cout.setf(ios::fixed) and cout.precision(3) if IO speed wasn't an issue (otherwise it would be printf("%.3lf", aDouble) or something from my asm library).
by Krzysztof Duleba
Wed Aug 09, 2006 12:52 am
Forum: C++
Topic: compile error, why?
Replies: 9
Views: 3295

setf and precision methods do change cout behaviour for all subsequent writes (I don't know about setprecision, though, I don't use it).
by Krzysztof Duleba
Tue Jul 25, 2006 11:16 pm
Forum: Volume 110 (11000-11099)
Topic: 11048 - Automatic Correction of Misspellings
Replies: 30
Views: 12499

Re: Thanks All

murkho wrote: Actually i think the problem is in Stl Library

The judge does not support some STL function.

How ever i changed All STL and Also the Algol i bit.
Now i got AC.
Actually darko was right and it was the lack of #include <cstdio> that caused the compilation error. Good that you got AC, though.
by Krzysztof Duleba
Tue Jul 25, 2006 11:05 pm
Forum: Bugs and suggestions
Topic: Contest status (for single user)
Replies: 4
Views: 1981

It doesn't work for me anymore, it only shows non-contest submissions. It used to work in the past, tough.
by Krzysztof Duleba
Tue Jul 25, 2006 10:44 am
Forum: Volume 110 (11000-11099)
Topic: 11053 - Flavius Josephus Reloaded
Replies: 22
Views: 10693

You get *a* period, not necessarily the least one.
by Krzysztof Duleba
Mon Jul 24, 2006 1:33 pm
Forum: Volume 110 (11000-11099)
Topic: 11055 - Homogeneous squares
Replies: 16
Views: 7839

OK, I agree it "boils down" to it if you know you can take that one more step further instead of simply following the directions ("reduce the first row and column to zero") What is the math behind it? Any explanation, plz. If cell [j] + cell[i-1][j-1] == cell[i-1][j] + cell [j-1] for each 0<i,j<n, t...

Go to advanced search