Sort and fixed print

Uncommented the sort thing that should never have been commented in the
first place and fixed print so it doesn't say deque()