Debugging in class

Can any one please hepl me wat was error in below pic.

You may think that it was not initialized dW in init function. But below example is working fine without inislising dW in init function. So please compare both the scrrenshots and debug. I’m waiting for replay.

For contact Whatsapp/Ph call: 8114772151

Hi,
You’re trying to initialise it as a multi dimentional list, which is why it has to look for a definition of variable.
It’s working as self.dW = 2 because it’s not multi dimentional, and the value here can be assigned directly during initialisation.
To summarize, in order to assign a value to one of the elements of a multi dimentional array, you have to create one in the first place.