I corrected mistakes in the top code
Also i changed this code as following:
..................
When debugging
and I can explain so: adds 2, then 4, then 1 but I see 2 and 4 changed places

(say myself-ok, maybe 4 is greater than 2) but at the end of debugging 6 has been located the most at the end.(it ought to 7) Why?
And can you explain it ( PriorityQueue rules without Comparator) please?
Thanks,
Rizvan
----------------------------------------------------------
My SCJP exam date approximately 15.03.2009