The action of cleaning of oily dirt by soap is based on -
presence of both hydrophilic and hydrophobic groups
The dirt particles on the cloth are organic in nature which is insoluble in water. Therefore, washing with water alone cannot remove dirt particles.
When soap is added to water then it forms micelles in water. Micelles have two parts that are - hydrophobic part (hydrocarbon part) and hydrophilic part (ionic part).
The hydrophobic end is attached to the dirt particle and removed from the cloth and the hydrophilic part remains in water. Therefore, both parts are used to remove the dirt from the cloth.
Hence, Option D is the correct answer.