Modify code to look more like example code