I have created a mapping which gives an array of structs.
mapping(address => BetByUser[]) betsByAddress;
I have tried changing this array, but with no success. Are these arrays in memory or storage? Can I change them, if yes, how?
arraysmappingsolidity
I have created a mapping which gives an array of structs.
mapping(address => BetByUser[]) betsByAddress;
I have tried changing this array, but with no success. Are these arrays in memory or storage? Can I change them, if yes, how?
Best Answer
Yes I coded up something, take a look, uncomment the part and change the parameter types for the respective part. Try to understand the following code, I have added some comments for better understanding.