Prabhakar S. answered 02/07/23
PhD in Chemistry with 30+ years of Teaching Experience.
Assuming magnesium hydroxide is present in excess and nitric acid is provided as a pure chemical ( not as a solution):
Conceptual map: g of HNO3 —> mole of HNO3 —> mole of Mg(NO3)2 —> g of Mg(NO3)2
3 g HNO3 * 1mole HNO3/ 63 g HNO3 * 1 mole Mg(NO3)2/ 2 moles of HNO3 * 148 g Mg(NO3)2 /1 mole of Mg(NO3)2. = 3.52 g ( round it off to 4 grams, with 1 sig. fig.)