Answer:
,

Step-by-step explanation:
pH is defined as the negative logarithm of the concentration of hydrogen ions.
Thus,
pH = - log [H⁺]
Strong acids dissociate completely and thus, 0.5 M of a solution of a strong acid yields a pH of 1.0 .
The expression of the pH of the calculation of weak acid is:-

Where, C is the concentration = 0.5 M
Given, pH = 4.0
So, for
,


pH = 4.0
Hence, the acid is HOCl.