Error in the code calculation
Minor changes