Skip to content

Commit

Permalink
fixed Advanced OOP typo
Browse files Browse the repository at this point in the history
  • Loading branch information
TiVentures committed Mar 16, 2018
1 parent 4b89720 commit f362d9e
Show file tree
Hide file tree
Showing 6 changed files with 1,237 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@
"source": [
"#### Step 5: Create a Customer class\n",
"\n",
"For this next phase, let's set up a Customer class that has a customer ID and can contain any number and/or combination of Account objects."
"For this next phase, let's set up a Customer class that holds a customer's name and PIN and can contain any number and/or combination of Account objects."
]
},
{
Expand All @@ -242,13 +242,16 @@
"outputs": [],
"source": [
"class Customer:\n",
" def __init__(self, name, cust_id):\n",
" def __init__(self, name, PIN):\n",
" self.name = name\n",
" self.cust_id = cust_id\n",
" self.PIN = PIN\n",
" \n",
" # Create a dictionary of accounts, with lists to hold multiple accounts\n",
" self.accts = {'C':[],'S':[],'B':[]}\n",
" \n",
" def __str__(self):\n",
" return self.name\n",
" \n",
" def open_checking(self,acct_nbr,opening_deposit):\n",
" self.accts['C'].append(Checking(acct_nbr,opening_deposit))\n",
" \n",
Expand Down Expand Up @@ -400,10 +403,13 @@
"outputs": [],
"source": [
"class Customer:\n",
" def __init__(self, name, cust_id):\n",
" def __init__(self, name, PIN):\n",
" self.name = name\n",
" self.cust_id = cust_id\n",
" self.PIN = PIN\n",
" self.accts = {'C':[],'S':[],'B':[]}\n",
"\n",
" def __str__(self):\n",
" return self.name\n",
" \n",
" def open_checking(self,acct_nbr,opening_deposit):\n",
" self.accts['C'].append(Checking(acct_nbr,opening_deposit))\n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@
"source": [
"#### Step 5: Create a Customer class\n",
"\n",
"For this next phase, let's set up a Customer class that has a customer ID and can contain any number and/or combination of Account objects."
"For this next phase, let's set up a Customer class that holds a customer's name and PIN and can contain any number and/or combination of Account objects."
]
},
{
Expand All @@ -242,13 +242,16 @@
"outputs": [],
"source": [
"class Customer:\n",
" def __init__(self, name, cust_id):\n",
" def __init__(self, name, PIN):\n",
" self.name = name\n",
" self.cust_id = cust_id\n",
" self.PIN = PIN\n",
" \n",
" # Create a dictionary of accounts, with lists to hold multiple accounts\n",
" self.accts = {'C':[],'S':[],'B':[]}\n",
" \n",
" def __str__(self):\n",
" return self.name\n",
" \n",
" def open_checking(self,acct_nbr,opening_deposit):\n",
" self.accts['C'].append(Checking(acct_nbr,opening_deposit))\n",
" \n",
Expand Down Expand Up @@ -400,10 +403,13 @@
"outputs": [],
"source": [
"class Customer:\n",
" def __init__(self, name, cust_id):\n",
" def __init__(self, name, PIN):\n",
" self.name = name\n",
" self.cust_id = cust_id\n",
" self.PIN = PIN\n",
" self.accts = {'C':[],'S':[],'B':[]}\n",
"\n",
" def __str__(self):\n",
" return self.name\n",
" \n",
" def open_checking(self,acct_nbr,opening_deposit):\n",
" self.accts['C'].append(Checking(acct_nbr,opening_deposit))\n",
Expand Down
Loading

0 comments on commit f362d9e

Please sign in to comment.