If you're planning to do memory management yourself, maybe don't pick a language that's designed to hide memory management as deep as it can from you, idk

Doing anything in a language that's designed to prevent you from doing that thing increases error surface by default