Changed d value to 0