Why using a temp variable here ?