Hi,
While doing the Dr. Who “Cadeau” puzzle I came cross what seems to be a bug.
PriorityQueue queue = new PriorityQueue(N, new BudgetComparator());
I tried to use java.util.PriorityQueue to sort my collection, it works in local using jdk1.7.0_65, unfortunately my queue wasn’t sorting properly on codinggame.com platform.
However, the code below works fine:
List queue = new ArrayList();
…
Collections.sort(queue, new BudgetComparator());