Sd2720 module using operators arrays and constructs lab


Module Using Operators, Arrays, and Constructs Lab

In this lab, you will complete three tasks related to multidimensional arrays and loops. The tasks performed in this lab will help you understand how to program common array operations and simplify programming by using loops.

Task 1-

Write a Java program with the following functionalities:

  • It should use a one-dimensional array.
  • It should enable the user to search for an element in the array.
  • If the element is found, it should display the number of occurrences.
  • If the element is not found, an error message should be displayed.

Task 2-

Create a Java application that stores and maintains the employee details, including employee ID, employee name, department, designation, marital status, and date of marriage, in a multidimensional array. The application should have the following functionalities:

  • When the user selects the enter data option, the inputs should be accepted.
  • Date of marriage should be accepted only if the employee' marital status is entered as "married."
  • When the user selects the view data option, all the employee details should be displayed.
  • When the user selects the exit option, the application should terminate.

Task 3-

Write Java programs to display the following patterns by using loops:

1252_Figure.png

Evaluation Criteria:

Your submission will be evaluated against the following criteria:

For Task 1

  • Does the code use a one-dimensional array?
  • Does the code enable the user to search for an element in the array?
  • Does the code display the number of occurrences if the element is found?
  • Does the code display an error message if the element is not found?
  • Is the code readable and documented?

For Task 2

  • Did you create a Java application that stores and maintains the employee details?
  • Does the code meet all the functional requirements?
  • Is the code readable and documented?

For Task 3

  • Did you write Java codes to display all three patterns?
  • Did you write the code using loops?
  • Are the codes readable and documented?

Solution Preview :

Prepared by a verified Expert
JAVA Programming: Sd2720 module using operators arrays and constructs lab
Reference No:- TGS01537904

Now Priced at $30 (50% Discount)

Recommended (92%)

Rated (4.4/5)