The primary cost factors that sway the price of roof replacement are ... The slope and shape of your roof—hipped, gabled or flat, for example—dictate the number of shingles, shakes or tiles ...