In the video why is the priority Queue initialized as follows:
pq(ropes, ropes+n)
Why is this queue initialized as ropes and then as ropes+n??
In the video why is the priority Queue initialized as follows:
pq(ropes, ropes+n)
Why is this queue initialized as ropes and then as ropes+n??
This is an array initialisation of priority queue.Basically we are putting all the values of an array(rope) in priority queue. +n means entire array