Update ex6_2.md to fix variable mismatch

The sell() method takes the nshares argument, however inside the method the variable shares is used instead.

This patch changes the name of the argument according to the variable used within the method.
This commit is contained in:
Jarle Thorsen authored and GitHub committed 2023-10-30 14:30:21 +01:00
1 parent afec76dd94
commit 92d7dc0f93
1 file changed
+1 -1
+1 -1
View File
@@ -160,7 +160,7 @@ class Stock(Structure):
def cost(self):
return self.shares * self.price
def sell(self, nshares):
def sell(self, shares):
self.shares -= shares
```