Today, dollar for dollar, is the 318 faster than the 340 ???

If the budget allows, i would probably run an aftermarket aluminum head. You have to objectively look at how much it would cost to redo the iron 340 core heads too, compared to aftermarket. Then, if you want your iron 340 to flow as good, toss in the cost of porting an iron head too?
(The last iron heads i had done, machine shop bill was $900. Mine were already professionally ported maxwedge heads. No way would i spend that on ordinarry 340 heads, short of a number matching, date coded restoration. )

A budget of $1500 was established for the 340 and $3k for the 318. With those miniscule budgets (I didn't make the rules), you'd have to assume both engines are 'usable' with minimal to no machine work necessary (ie. backyard rebuild, hone, re-ring, bearing, lap valves, and reassemble).

If the 340 needed new heads, it's probably out of the discussion all together. If the 318 needed heads, that $3k starts decreasing very quickly and pretty much eliminates the possibility of the 50 extra cubes.