First piece of working code.