OOPS Assignments

OOPS Assignments

Varanasi Software Junction:OOPS Assignments








  1. Bank Account class
    1. Store accountno, customer name and balance
    2. Make a constructor taking these three data items as input
    3. Make a str/toString method to show data properly
    4. Add a deposit function that takes an integer as input and adds to the balance
    5. Add a withdraw method that allows withdrawing money from the balance.
    6. Validate properly

  2. A Bank with multiple accounts
    1. Add a menu based system like this
      0-Exit,1-create account,2-deposit,3-withdraw,4-show balance
    2. Store accounts in an array. Use the previous account class.
  3. Time class
    1. Make a class called time that takes as input hour and minute in 24hrs format and then prints it in 12hrs format. Eg 11:45= 11:45 AM, 12:45 = 12:45 PM, 13:45 = 01:45 PM.
    2. Single digit must always be preceded with 0 7:8 will be 07:08 AM


Contact us for software training, education or development










 

Post a Comment

0 Comments