Search found 10 matches

by xshaka
7 years ago
Forum: Algorithms
Topic: HEAP
Replies: 1
Views: 2108
Gender: None specified

Re: HEAP

Typically in ACM-ICPC style contests, you won't need nothing beyond a "normal" heap. Fibonacci heaps are a very weird data structure which I've seen used rarely just to make Djkstra algorithm extra fast for some online judges problems where it was required. Here you have my solution for http://www.s...
by xshaka
7 years ago
Forum: Algorithms
Topic: Matching in a general graph
Replies: 3
Views: 4139
Gender: None specified

Re: Matching in a general graph

Actually, there is a known efficient algorithm for this problem: Edmonds algorithm (Edmonds not Edmonds-Karp, since that last one is for max flow). The idea is to build an arbitrary matching and then the algorithm improves it to make it maximum. Here you have my own implementation. struct edge { int...
by xshaka
7 years ago
Forum: Problem set
Topic: 1571 - Bus System
Replies: 23
Views: 3758
Gender: None specified

Re: 1571 - Bus System

Still waiting for reply from system managers. When got it, I´ll post it here.
by xshaka
7 years ago
Forum: Problem set
Topic: 1571 - Bus System
Replies: 23
Views: 3758
Gender: None specified

Re: 1571 - Bus System

There should be something wrong on with the system because as long as I remember, there is no case 16 in the test data. Will check that as soon as possible.
by xshaka
7 years ago
Forum: Problem set
Topic: 1571 - Bus System
Replies: 23
Views: 3758
Gender: None specified

1571 - Bus System

The statement of this task has been updated to fix non-clear situations and consecuently the tests have changed. We sorry about all problems this may cause.
by xshaka
7 years ago
Forum: Problem set
Topic: 1760 - Triple Sums
Replies: 1
Views: 365
Gender: None specified

Re: 1760 - Triple Sums

The time limit for this problem has been reseted and all solutions have been rejudged. Some users have lost their AC status.
by xshaka
7 years ago
Forum: Problem set
Topic: 1571 - Bus System
Replies: 23
Views: 3758
Gender: None specified

Re: 1571 - Bus System

I don't actually get the idea behind your simulation code, i will try to find a small test case where our results differ and will see which one is correct. You will be notified about the test case by this way.
by xshaka
7 years ago
Forum: Problem set
Topic: 1571 - Bus System
Replies: 23
Views: 3758
Gender: None specified

Re: 1571 - Bus System

Hi, still not reviewing the whole code, but I think you're missing a statement from the problem:

"If two or more groups arrive at the same time, they will break ties according to the group size: smaller groups will get in before larger groups".

Can't see how are you taking care about that exactly.
by xshaka
7 years ago
Forum: Problem set
Topic: 1571 - Bus System
Replies: 23
Views: 3758
Gender: None specified

Re: 1571 - Bus System

Hi, my approach is similar I guess: I simulate the travel performed for every bus, but I think the key difference is I do need a more specific data structure for picking which group will get the bus at each stop. Could you please post your code? (it is allowed as long the code is not an AC code).
by xshaka
7 years ago
Forum: Problem set
Topic: 1571 - Bus System
Replies: 23
Views: 3758
Gender: None specified

Re: 1571 - Bus System

Hi ReynaldoGil:

I'm the creator of the Bus System problem, and even when the problem test data has been checked for some other judges before being posted, we may be wrong. Can you please comment your approach here?

Best regards.

Go to advanced search