Why does heapq.heapify not alter a list when a slice thereof is passed to it?

前端 未结 0 1699
既然无缘
既然无缘 2021-01-05 17:48

According to a previous answer

Slicing lists does not generate copies of the objects in the list; it just copies the references to them.

相关标签:
回答
  • 消灭零回复
提交回复
热议问题