Cleans up examples
Moves examples into code