Hi @prathyoo,
a solution in no code would be to create a choice with only one answer "yes" in your case. The column must be set to required and the default to none.
That way, they will have to select yes from the dropdown and the form cannot be submitted otherwise.
Other than that you will need to use javascript.
Hope that helps. Please mark the solution if it solves your problem.