nnCostFunction vectorized, loop over lambda in main