The correct option is D PbI2
Since the crystalline compound (B) dissolves in hot water and gives a yellow precipitate with NaI, it should be lead chloride, PbCl2 and the solution (A) consists a lead salt.
PbCl2+2NaI→PbI2+2NaCl
(B, white ppt.) (D, yellow ppt)
The compound (A) does not give any gas with dilute HCl but liberates a reddish brown gas on heating, it should be lead nitrate, Pb(NO3)2.
2Pb(NO3)2→2PbO+2NO2+O2
(A) (reddish brown gas)
Lead chloride is sparangly soluble in water. When H2S is passes, it gives a black precipitate of lead sulphide, PbS.
PbCl2+H2S→PbS+2HCl
(C, black ppt)