costos_fijos = 500
costo_variable_unitario = 15
precio_venta = 25

print("Cantidad | Ingresos | Costos Totales | Utilidad")
print("---------|----------|----------------|---------")

for cantidad in range(0, 1050, 50):
    ingreso = precio_venta * cantidad
    costo_total = costos_fijos + (costo_variable_unitario * cantidad)
    utilidad = ingreso - costo_total
    
    if utilidad >= 0:
        print("{:>8} | ${:>7} | ${:>14} | ${:>8}".format(cantidad, ingreso, costo_total, utilidad))

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: