Course1 Week3 Exercise2

hello.

please, for the compute_cost, should we add the parameter lambda?

when i code with the prameter, i get an output close to the expected one (0.218 instead of 0.219) and when i code without the paramater, i get an output far from the expected output.

in both cases, i get 66% and the same comments. incorrect compute_cost.

looking for help.

thanks.

Hi @kazoule, you don’t have to add regularization term in compute_cost function.
You need to add regularization term in compute_cost_reg function, whose implementation is further down in programming exercise.

@ritik5,the first time i coded without the parameter and got an output far from the expected.

i will try again