Write a Java application and use a Two dimensional array to store five Dutch, French and Italian translated words. Use a single array to store the English words.
Q.2.1 Contain a single array to contain the following five English words and a Two dimensional array to store the following Dutch, French and Italian translated words.
ITALIAN WORD
cielo
correre
studia
musica
cane
ciel
courir
etude
musique
chien
hemel
rennen
studie
muziek
hond
FRENCH WORD
Your program must:
ENGLISH WORD
sky
study
music
run
dog
DUTCH WORD
Build a class Department having id (int), address (String) and projects (array list of projects) and workers (array list of workers) a. Provide parameterized constructor Department (String address) which initialized id randomly and array lists as empty array lists. Provide in department class void addProjectWork(int pid, int wide, int hours)
This will add the hours to the worker of the given project. For this you will need to call the appropriate method of the project class i.e addMemberHours which adds the hours for the specified member as well as add to duration of the project
Build a class Project with id(int) , desc (String), duration (int) , budget (double) and members (ArrayList of Workers). a. Provide a parameterized constructor Project (int id, String desc, double budget). The member array will be initialized as empty array and the initial duration of the project will be 0 b. Provide setters for description and budget and getters for all except members list. Provide a method getTotalCost() that calculates the total cost of the project by summing the budget and the salary of each member of the project. The salary of each m ember can be found by calculating an appropriate method of the Worker class.
Build a class Project with id(int) , desc (String), duration (int) , budget (double) and members (ArrayList of Workers). Provide a parameterized constructor Project (int id, String desc, double budget). The member array will be initialized as empty array and the initial duration of the project will be 0 b. Provide setters for description and budget and getters for all except members list
Provide a method getTotalCost() that calculates the total cost of the project by summing the budget and the salary of each member of the project. The salary of each member can be found by calculating an appropriate method of the Worker class .
Build a class Department having id (int), address (String) and projects (array list of projects) and workers (array list of workers) a. Provide parameterized constructor Department (String address) which initialized id randomly and array lists as empty array lists b. Provide getters for id and address and setter for address only.
Provide a method getDepartmentTotalBudget() that calculates the total cost of each project of the department and adds it up to get the total budget (You will call appropriate method of the Project instances to get the project costs). Please provide in department class void addProjectWork(int pid, int wide, int hours) This will add the hours to the worker of the given project. In this you will need to call the appropriate method of the project class i.e addMemberHours which adds the hours for the specified member as well as add to duration of the project
write a code for bresenham line drawing algorithm in processing.org
Build a class Department having id (int), address (String) and projects (array list of projects) and workers (array list of workers) a. Provide parameterized constructor Department (String address) which initialized id randomly and array lists as empty array lists b. Provide getters for id and address and setter for address only c. Provide a method addWorker(int id, String name, double salRate) that creates an instance of Worker and adds it to the workers list d. Provide a method addProject(int id, String description, double budget) that creates a project and adds it to the project list e. Provide method addWorkerToProject(int projId, int wId) that searches for the project with projId from the projects list and worker with wId from the members lists and then adds the member to the project (you will call appropriate method of the project class that will add the member to the project. See blow the project class for details. f.
1. Build a class Department having id (int), address (String) and projects (array list of projects) and
workers (array list of workers)
c.
a method addWorker(int id, String name, double salRate) that creates an
instance of Worker and adds it to the workers list
d. Provide a method addProject(int id, String description, double budget) that creates a
project and adds it to the project list
e. Provide method addWorkerToProject(int projId, int wId) that searches for the project
with projId from the projects list and worker with wId from the members lists and then
adds the member to the project (you will call appropriate method of the project class
that will add the member to the project. See blow the project class for details.
f. Provide a method getProjectCost(int pid) which searches for the project with the given
id from the projects list and then returns its total cost (you can call a method from the
project class to get the total cost… see the project class for details)
Worker having id(int), name(Sting), hoursWorked(int), salRate (double).a method addHours(int h) that increase the number of hoursWorked by the provided value.getCurrentSalary()that calculates and returns the current salary i.e. the hoursWorked times the salRate. class Project with id(int),desc (String), duration (int), budget (double) and members (ArrayList of Workers).methodaddMember(Worker m) that adds the worker instance to the members array list.a method Worker getMember(int wId) that searches for the worker with the given id in the members list and returns instance.Provide a method addMemberHours(int wId,int h) that finds the Worker with the wID in the members list and then adds worker hours to the instance. These many hours should also be added to the duration of this project,getTotalCost() that calculates the total cost of the project by summing the budget and the salary of each member of the project. The salary of each member can be found by calculating an appropriate method of the Worker class.
Provide a method getTotalCost() that calculates the total cost of the project by summing
the budget and the salary of each member of the project. The salary of each m ember
can be found by calculating an appropriate method of the Worker class