There's not much to compute here in these problems, because the COP (coefficient of performance) for heating is defined as heat delivered to the hot reservoir divided by the work done. So in each of part (a) and (b), the work (electrical) is 2900/3.0 ~= 967 J (round it as you will).
What's unrealistic about parts (a) and (b) is that one would not expect the same heat pump to show identical COP at two different ΔT conditions!
Parts (c) and (d) ask you to calculate the (ideal) COP, and compute with that, so for example with (c), you need (273.15+22)/(22) as your COP,and work (as above) from there.
You will note that (1) operating COP of heat pumps is typically far below the theoretical maximum, but that, (2) in spite of that, heat pumps usually easily beat natural gas heating for cost, except in rare highly urbanized areas where natural gas is cheap and electricity is expensive (think about that one -- why aren't all commodities cheaper in big cities?).