Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Term Project, Spring/Summer 2017 CSC 2110, Computer Science I Due 07/24/2017 and

ID: 3853896 • Letter: T

Question

Term Project, Spring/Summer 2017 CSC 2110, Computer Science I Due 07/24/2017 and 07/26/2017 class time

Mini Bank Account Management System: This system aimed to computerize the bank account management operations such as open an account, withdraw money, deposit money etc.

Modules: There are three main parts of the system: 1) Person, Student and Teacher objects, where Person needs to be declared as an abstract base class and Student & Teacher should be declared as derived class. 2) Bank Account containing the account holder 3) Bank transactions such as open an account, withdraw and deposit money

Main Menu: Main Manu consists of the following items:

1) Main Menu

2) Administrator Menu

3) Open Account

4) Close Account

5) Withdraw Money

6) Deposit Money

7) Display Account holder with maximum deposit

8) Exit If user choose the Administrator menu then system will display another submenu, which will show the following submenu options:

1) Create Student Record

2) Display All Student Records

3) Display All Students by Last Name

4) Display Specific Student Record

5) Modify Student Record

6) Delete Student Record

7) Create Teacher Record

8) Display All Teacher Records

9) Display Specific Teacher Record

10) Modify Teacher Record

11) Delete Teacher Record

12) Return to Main Menu

Data storage: data can be stored in a text file. Therefore, you must use the file read and write operations for data retrieval and storage. For this system, three files required: Student.txt, Teacher.txt and Bank Account.txt.

N.B: The above requirements can be considered as a guideline for this project. You can provide more functionalities for the proposed system. However, the above features must be present to achieve full credits from this Term Project. All inputs must be considered and displayed a proper error message. You can create a simple console based project with the above menu, where the system will prompt the user to enter the corresponding number from the keyboard to execute an operation. e.g. user needs to enter 3 for opening a bank account.

The Programming should be in C++ language.

Explanation / Answer

import java.util.*;
public class PersonTest
{
public static void main(String[] args)
{
Person[] people = new Person[2];
people[0] = new Employee("Harry Hacker",10000, 2000, 08, 3);
people[1] = new Student("Maria Morris", "computer science");
for (Person p : people)
System.out.println(p.getName() + ", " + p.getDescription());
}
}
abstract class Person
{
public Person(String n)
{
name = n;
}
public abstract String getDescription();
public String getName()
{
return name;
}
private String name;
}
class Employee extends Person
{
public Employee(String y, double s, int year, int month, int day)
{
super(y);
salary = s;
GregorianCalendar calendar = new GregorianCalendar(year, month - 1, day);
hireDay = calendar.getTime();
}

public double getSalary()
{
return salary;
}
public Date getHireDay()
{
return hireDay;
}
public String getDescription()
{
return String.format("an employee with a salary of $%.2f", salary);
}
public void raiseSalary(double byPercent)
{
double raise = salary * byPercent / 100;
salary += raise;
}

private double salary;
private Date hireDay;
}
class Student extends Person
{
public Student(String y, String m)
{
super(y);
major = m;
}
public String getDescription()
{
return "a student majoring in " + major;
}
private String major;
}

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote