Fixed compiler errors for coding challenge

Brandon's pull request for coding challenge.