Question: I have a 2D numpy array called arr. The current value of row 100001 is [32090, 543]. I need to modify the first value only,
I have a 2D numpy array called arr. The current value of row 100001 is [32090, 543]. I need to modify the first value only, leaving the 543 alone. So the new value of that row would be [46656, 543]. How do you modify only the first element? It tried --> arr[100000]=[46656,] but that just modified both of them --> [46656, 46656]
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
