Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

using python 1) a) Define a class named Account and its subclass checkingAccount. Both of the classes take balance and accountHolder as arguments and have

using python

1)

a) Define a class named Account and its subclass checkingAccount. Both of the classes take balance and accountHolder as arguments and have deposit method. This deposit method manages the deposit actions. In class Account, when a deposit is done, it prints 'Thank you' and in checkingAccount, when a deposit is done, it prints 'Salary. Also, define a class variable called interest whose value is 0.02.

b) Create two objects : one for class Account, the other for class checkingAccount. Class Account : batman and the balance is 0 Checking Account : superman and balance is 100 Deposit 30 dolar to each classes and print the balance for each one. (10 points)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions

Question

Use service tiering to manage the customer base and build loyalty.

Answered: 1 week ago