Updated and simplified example
Restructured and made it a bit more DRY