rearranging nested class examples to be more clear