Separated code blocks

Split up code sections so it's more obvious that the code snippets go in different sections.