We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Fighting Armies
Fighting Armies
Sort by
recency
|
10 Discussions
|
Please Login in order to post a comment
scala and the power of PriorityQueue :)
Test 11 is giving "Wrong answer", but when I run it locally I get no differences from the expected output.
I am also getting "Wrong answer" for all later tests, but haven't yet investigated.
Any ideas?
Hey Guys, could anyone help me? I submitted Scala solution for this where I used mutable heap and InputStreamReader and BufferedStreamReader, but test-cases: 16, 18, 19 are still time-outed... I don't know how I could deal with IO more efficiently. I guess, it's the IO causing these timeouts.
Any help would be great.
Thank you!
Tests 16, 17, 18, 19 always return "Runtime Error". It seems to be caused by "time limit" since those tests run correctly on my laptop. But I have already optimized code with IOVector and ByteString-based IO. I have tried various logarithmic heap structures including LeftiestHeap, BinomialHeap, and IntMap. No luck! Anyone facing the same problem here?
what's the fastest of way of reading input using scala ? i've tried couple of options using readLine, Source.stdin.getLines but all of them ended with timeouts for 4 of the tests (16,17,18,19 to be specific)..