ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1280. Topological Sorting

Memory limit
Posted by Fyodor Menshikov 27 Oct 2006 12:11
On original contest memory limit for this problem was 512 kb. The problem was designed so that input file must be read twice and (important!) it is impossible to create array N^2 of boolean. Solutions that used array 1000x1000 of boolean got MLE. Of course in Timus it is impossible to read input twice, but it is quite possible to prohibit creating N^2 matrix. I think that 1 Mb memory limit should be good for this problem. Of course, one more problem not solvable in Java will appear.