Heuristic optimization of the general life history problem: A novel approach