rearranging encapsulation examples for easy playground use