Does it output any error?
declare mu= and Var= outside the loop
ok, now i got it. thank you for clearing the doubt.