ADT ,data structure (ArrayList), sorting

Ads
 

ADT ,data structure (ArrayList), sorting

Write a program to calculate a bonus for 10 employees of WAFA Supermarket. The program consists of an abstract class Employee. Each employee contains IC number, name, basicSalary, noOfYearService, set methods for each attributes and an abstract method calculateBonus(). Cashier and Supervisor are the subclasses of Employee class. Both subclasses contain bonus attribute and method calculateBonus(). Bonus for a supervisor is calculated by basicSalary * 25% *noOfYearService while bonus for a cashier is basic salary * 15% *(noOfYearService/2).

Store each employee information in different arrayList depending on his/her position (cashier or supervisor).

The program displays a menu with choices ( 1. to add employee information, 2. to delete employee, 3. to display report). Below is a sample format of a report when a user chooses to display a report..

can help me to identify what set methods that should have in this program..and can help me..give some clue in coding..how to start this program..

View Answers

Ads









Related Tutorials/Questions & Answers:
ADT ,data structure (ArrayList), sorting
ADT ,data structure (ArrayList), sorting  Write a program to calculate a bonus for 10 employees of WAFA Supermarket. The program consists... in different arrayList depending on his/her position (cashier or supervisor
Sorting arraylist without using Collection.sort()
Sorting arraylist without using Collection.sort()  Hi, How can I sort an arraylist without using Collection.sort() nad also I am not allowed to use any other data structure in the program? Is there any algorithm by using which I
Advertisements
Sorting an ArrayList
Sorting an ArrayList  print("code sample");Hello All, I am working on a program for school and I am having trouble with sorting my list. The numbers I receive in my output are correct, but not in ascending order as required
sorting and storing data
sorting and storing data   sorting and storing data in UITableView
Data structure
Data structure: How to sort numbers in a queue using a bubble sort method?  How to sort numbers in a queue using a bubble sort method
data science course structure
data science course structure  Hi, I am beginner in Data Science and machine learning field. I am searching for the tutorials to learn: data science course structure Try to provide me good examples or tutorials links so
sorting
sorting   write a program to arrange sorting in rows,column and diagonal
How to Display Data in a tree structure on the GUI
How to Display Data in a tree structure on the GUI  how to display data in a tree structure on the GUI? I need this sort of UI to display data showing a set of rules showing various conditions and the actions related
Sorting
Sorting  can any help me know which sorting algorithm java uses for sorting collection and arrays
array ADT
array ADT  Write a program using array_ADT to retrieve a list of elements from a file
array ADT
array ADT  Write a program using array_ADT to retrieve a list of elements from a file
sorting
sorting  write to a program to arrange the sorting in rows, column and digonal
sorting
sorting  how to do sorting without using bubble sort,selection sort
extracting column and sorting csv data alphabetically
extracting column and sorting csv data alphabetically  hi here is my code and csv data save it as country.csv file *Australia;AU;1.5 Thaialnd;TH;1.6 India;IN;1.7 Malaysia;ML;1.8 Japan;JP;1.9 Korea;KO;1.10 Bangladesh;BD;1.11
array ADT
array ADT  Write a program using array_ADT to retrieve a list of URLs from a file. In your program take an array index as the input and delete the entry corresponding to that index
arraylist of an arraylist
arraylist of an arraylist  Can anyone suggest me how to use arraylist of an arraylist?? how to put data into it and get data from it???? becoz i want to make rows and column dynamic which can grow as per requirement?????/ plz
arraylist
arraylist  Hi how can we eliminet duplicate element from arraylist in java? how can we achieve data abstrcation and encapulation in java? how many type of modifier are there in java? Thanks kalins anik   Remove
arraylist
arraylist  Hi How can we eliminet duplicate element from arraylist? How can we find highest salary from arraylist ? How can we highest key value pair from map? Thanks Kalins Naik   Remove duplicates from Arraylist
arraylist
arraylist   Using arraylist class , what type of exception are throws, how can write a java programe   An ArrayList can throw... ArraylistException { void buildAlphabet() { ArrayList list = new ArrayList
arraylist
data into an arraylist and display the data of the particular employee according...arraylist  Hi i have class A , i have added employee name and id in arraylist, then how can i find out all infomation of class A using emplyee
group by sorting
group by sorting  group by sorting of data in SQL
ArrayList
ArrayList  import java.util.*; class ArrayListDemo2 { public static void main(String args[]) { ArrayList al=new ArrayList(); al.add("one"); al.add("two"); al.add("three"); al.add("four"); for(int i=0;i Expected
ModuleNotFoundError: No module named 'adt'
ModuleNotFoundError: No module named 'adt'  Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'adt' How to remove the ModuleNotFoundError: No module named 'adt' error
Is there a data structure like a class that doesn't need to be defined as a class in it's own file?
Is there a data structure like a class that doesn't need to be defined... another charge. However, I recall once seeing a data structure that one could create... simply make one ArrayList that included each variable I need. Does such a data
arraylist
% *(noOfYearService/2). Store each employee information in different arrayList depending on his
sorting and filtering the displayed table data using jsp and xml
sorting and filtering the displayed table data using jsp and xml  I have created a xml file and a jsp file, which uses DOM parser to display the content of xml file in web page. Now I would like to sort and filter those data
How Can I get ArrayList of Data from jsp with ajax request
How Can I get ArrayList of Data from jsp with ajax request  Hi, I retereved 5 Employee Record of Data from Struts Action class to jsp with ajax response. But I don't how how can reterve this dynamic 5 employee records
Java ArrayList Example
demonstrates you the use of ArrayList. An ArrayList is a data structure. It can...Java ArrayList Example  How can we use array list in java program..."); array.add("Arun"); System.out.println("ArrayList Size
ArrayList object
ArrayList object  i have am ArrayList object it containg data base records in it, now i want to display this ArrayList object data in my jsp programe, plz help me
Sorting in Java
Sorting in Java  Sorting in Java
ModuleNotFoundError: No module named 'adt-extension'
ModuleNotFoundError: No module named 'adt-extension'  Hi, My... 'adt-extension' How to remove the ModuleNotFoundError: No module named 'adt-extension' error? Thanks   Hi, In your python

Ads