Deskera Hiring Test
Implement an Employee Manager for a Company so that the HR Admins can
- Add a new Employee
- Find any Employee by Employee Id
- Find all Employees older than X years (So if X = 30 then all employee who are older than 30 years. For e.g. Employees with age 31, 32, 40, etc but employees with age 30 years are not included)
- Delete any Employee at the time of employee exit
- List all the current Employees
- When an Employee is added, the information being provided is
Full Name
andBirth Date
. These are mandatory fields. - The system must store
First Name
andLast Name
separately in theEmployee
object - The system must store
ageInYears
andageInMonths
separately in theEmployee
object Full Name
can have names suchJohn
,John Doe
,John P. Doe
,John Paul Doe
. The way to break the names down in first name and last name are as followsFull Name First Name Last Name John John John Doe John Doe John P. Doe John P. Doe John Paul Doe John Paul Doe - No two employees with same
Full Name
andBirth Date
are allowed i.e. We can not have twoJohn Doe
born on1-Jan-1990
. Employee Id
has to be generated by the system and for every new employee a new and unique employee id must be generated.- Accetable format for
Birth Date
isDD-MON-YYYY
. For e.g.1-Jan-1990
,2-Feb-1991
. Other formats such asJan-1-1990
,01/01/1990
,1990-01-01
, must not be accepted by the system ageInYears
andageInMonths
should be rounded up. For e.g. a person born on1-Jan-2020
will haveageInYears
as2
andageInMonths
as15
- The EmployeesManager skeleton code is in src/EmployeesManager.java
- The implementation must be in this file only and no new files can be added to the code.
- Only Java SDK can be used and no other dependencies/ library can be used.
- Please
Fork
the repository, keep it public and while submission, provide your repository URL.