Was there a purpose why the US continued to make 2 different bombers? Instead of a B-24 and a B-17 why not just one and then mass produce it like they did the Sherman tank?

Same goes for the Brits.They had the Lancaster and Halifax. Feel free to add your opinions on each.