Least number of temporary variables required to create three address code in static single assignment form for the expression $p+q*r-s/(q*r)$
You used the optimisation of calculating q * r only once. Maybe someone considered that "cheating" and is insisting that it must be calculated twice. I wouldn't agree with that at all, but it would explain the different answers.