Cougars upset Arizona, 24-17