This question was asked in Ex 10.5, 6

Image.jpg que 9 no.2 solution with whole method

Kashish Sindhi's image