Hello, Haily,
Let's first determine the number of moles contained in 10 grams of N2. The molar mass of N2 is 28.0 grams/mole.
(10.0 g)/(28.0 grams/mole) = 0.357 moles N2.
4000J of energy leaves the system. We can write this as -4.00 kJ,
The molar enthalpy is thus (-4.00kJ)/(0.357 moles N2) or -11.2 kJ/mole