Hi,
With regards to week1/max_pairwise_product.py
would you please explain what does "if max_index1 == -1" do in the if condition in the for loop?
since max_index1 is initially assigned to -1, why do we need that in the if loop again? I did test it and knew that the answer wouldn't be right without that condition, but I can't figure out why.
Thanks!
Hi,
With regards to week1/max_pairwise_product.py
would you please explain what does "if max_index1 == -1" do in the if condition in the for loop?
since max_index1 is initially assigned to -1, why do we need that in the if loop again? I did test it and knew that the answer wouldn't be right without that condition, but I can't figure out why.
Thanks!