To calculate goodwill, we need to adjust profits based on stock values.
If closing stock is overvalued, it means profits are inflated.
So, we need to reduce this inflated profit from the current year's profit (A) and also consider how it affects next year's profit (C).
Option (D) is not relevant because we don't add to previous year's profit in this context.
Thus, the correct adjustments are (A) and (C) only.
Final answer: Option 2.