Remove all nodes in linked list

前端 未结 4 1136
清酒与你
清酒与你 2021-01-29 06:03

I have a linked list contains 3 nodes like the image shown: \"enter

There is a head pointe

4条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2021-01-29 06:23

    Instead of free, C++ uses delete function.

    Check the link to have deep knowledge about all kind of operations(including recursive or iterative delete) on linked lists.

提交回复
热议问题