Duality and products in algebraic (co)homology theories