A 30.5 g sample of an alloy at 92.4°C is placed into 52.9 g water at 24.1°C in an insulated coffee cup. The heat capacity of the coffee cup (without the water) is 9.2 J/K. If the final temperature of the system is 31.1°C, what is the specific heat capacity of the alloy? (c of water is 4.184 J/g×K)

heat lost by alloy + heat gained by water + heat gained by coffee cup = 0

You have three segments above. Substitute the following into the appropriate part and solve for the only unknown in the bunch which is specific heat of the alloy.
Heat lost by alloy is as follows:
mass alloy x specific heat alloy x (Tfinal - Tinitial)

Heat gained by water is as follows:
mass H2O x specific heat H2O x (Tfinal-Tinitial)

heat gained by coffee cup is as follows:
heat capacity x (Tfinal-Tinitial)