Circuit Cost

There is a cost to building a circuit. Each input is +1 Each gate is +1 Inverters don’t cost anything