French software engineer with 15 year experience on 3D data visualisation and processing. Lots of C++, and switch to Unity recently.
I like when it run fast 😉
Glad to see that some still accord importance to data structure 😀
I advice you to replace naked pointer (aka node*) by smart pointer like std::shared_ptr. The small overhead introduced by smart ptr is largely counterbalanced by the better and easier memory management you will gain.
You save time by not handling crazy memory issues => you have more time to do real optimization to your algorithm => your program runs faster.
Hi !
Glad to see that some still accord importance to data structure 😀
I advice you to replace naked pointer (aka node*) by smart pointer like std::shared_ptr. The small overhead introduced by smart ptr is largely counterbalanced by the better and easier memory management you will gain.
You save time by not handling crazy memory issues => you have more time to do real optimization to your algorithm => your program runs faster.
Thank you very much for your advice. I am still a student and have much to learn <3