A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data.
You didn't mention what you wanted if both H2 and I2 have a balance, so this formula doesn't account for that, but this will do the rest of what you want in the order of checking H2 first, and then I2:
=IF(H2<>"",-27,IF(I2<>"",-11,0))