The smallest Topological Sort (#507) - Azerbaijan Computing Olympiad