所以一個可行的方案是將原本的entry 做一個標記表示它已經被刪除,並新增一個擁有新的priority 的entry 。 pq = [] # list of entries arranged in a heap entry_finder = ...
確定! 回上一頁