remove outdated comment
improve memory management example and comments