exercise2 changed rgb division to double