Smart pointers are preferred as they free the memory when they leave scope
Smart pointers are preferred as they free the memory when they leave scope