Added stack and shared pointer allocation examples