Questions
For this assignment, you will take on the role of software developer as part of a...

For this assignment, you will take on the role of software developer as part of a team of developers for a retail company. The payroll manager of the company has tasked you with developing a Java program (if you can put it in NetBeans that would be awesome) to quickly calculate an employee’s weekly gross and net pay. The program must prompt the user to enter the employee’s name, rate of pay, and hours worked. The output will display the information entered into the program along with the calculations for gross pay, total amount of deductions, and net pay.

In this coding assignment, you will utilize the Java syntax and techniques you learned while reviewing the required resources for Week 1. You may select appropriate variable names as long as proper Java syntax is used. You will also submit your source code.

Input:
In the input section, utilize Java syntax and techniques to input the employee’s name, rate of pay, and hours worked. The input should be completed either via keyboard or via file.

Processing:
In the processing section, the following calculations will need to be performed in the processing section:

  • Gross Pay:
    Gross pay if hours worked are 40 hours or less = hours worked * rate of pay
    Gross pay if hours worked are greater than 40 hours = ((hours worked – 40) * (rate of pay * 1.5)) + (40 * rate of pay)
    • Example – Employee worked 55 hours. The employee’s rate of pay is $10.00.
      ((55 – 40) * (10 * 1.5)) + (40 * 10) = 625
      The gross pay is $625.
  • Deductions:
    Deductions are calculated based upon the following rates:
    • Federal Tax = 15%
    • State Tax = 3.07%
    • Medicare = 1.45%
    • Social Security = 6.2%
    • Unemployment Insurance = .07%

The following calculations are used to calculate each deduction:

  • Federal tax amount = federal tax rate* gross pay
  • State Tax amount = state tax rate * gross pay
  • Medicare amount = Medicare rate * gross pay
  • Social Security amount = social security rate * gross pay
  • Unemployment Insurance amount = unemployment insurance amount * gross pay

Total deductions = Federal Tax amount + State Tax amount + Medicare amount + Social Security amount + Unemployment Insurance amount

  • Net Pay:
    The net pay amount is calculated as follows:
    Net pay = gross pay amount – total deductions

Output:
The Java program should display the following information:

  • Employee Name
  • Rate of Pay
  • Hours Worked
  • Overtime Worked
  • Gross Pay
  • Total amount of deductions
  • Net Pay

In: Computer Science

In this assignment will demonstrate your understanding of the following: 1. C++ classes; 2. Implementing a...

In this assignment will demonstrate your understanding of the following:

1. C++ classes;

2. Implementing a class in C++;

3. Operator overloading with chaining;

4. Preprocessor directives #ifndef, #define, and #endif;

5. this – the pointer to the current object.

In this assignment you will implement the Date class and test its functionality.

Consider the following class declaration for the class date:

class Date

{

public:

Date(); //default constructor; sets m=01, d=01, y =0001

Date(unsigned m, unsigned d, unsigned y);

//explicit-value constructor to set date equal to today's

//date. Use 2-digits for month (m) and day (d), and 4-digits for year (y); this function should //print a message if a leap year.

void display();//output Date object to the screen

int getMonth();//accessor to output the month

int getDay();//accessor to output the day

int getYear();//accessor to output the year

void setMonth(unsigned m);//mutator to change the month

void setDay(unsigned d);//mutator to change the day

void setYear(unsigned y);//mutation to change the year

friend ostream & operator<<(ostream & out, const Date & dateObj);//overloaded operator<< as a friend function with chaining

//you make add other functions if necessary

private:

int myMonth, myDay, myYear; //month, day, and year of a Date obj respectively };

You will implement all the constructors and member functions in the class Date. Please see the comments that follow each function prototype in the Date class declaration above; these comments describe the functionality that the function should provide to the class.

Please store the class declaration in the file “date.h” and the class implementation in the file “date.cpp” , and the driver to test the functionality of your class in the file “date_driver.cpp”.

S A M P L E O U T P U T FORAssignment#2

Below I have provided a skeleton with stubs and a driver to help you get started. Remember to separate the skeleton into the appropriate files, and to include the appropriate libraries.

You should submit the files “date.h” , “date.cpp” , and “date_driver.cpp” together in a zip file named with the format “lastname_firstname_date.zip” to Canvas before the due date and time. Usually the tool you use to create a zip file will automatically append “zip” to the end of the filename.

Notes:

1. ALL PROGRAMS SHOULD BE COMPILED USING MS VISUAL STUDIO C++!

2. Information on Month: 1 = January, 2 = February, 3= March, …, 12 = December

3. Test the functionality of your class in “date_driver.cpp” in the following order and include messages for each test:

a. Test default constructor

b. Test display

c. Test getMonth

d. Test getDay

e. Test getYear

f. Test setMonth

g. Test setDay

h. Test setYear

4. See sample output below.

5. See skeleton below.

S A M P L E O U T P U T FORAssignment#2

Default constructor has been called

01/01/0001

Explicit-value constructor has been called

12/31/1957

Explicit-value constructor has been called

Month = 15 is incorrect

Explicit-value constructor has been called

2/29/1956

This is a leap year

Explicit-value constructor has been called

Day = 30 is incorrect

Explicit-value constructor has been called

Year = 0000 is incorrect

Explicit-value constructor has been called

Month = 80 is incorrect

Day = 40 is incorrect

Year = 0000 is incorrect

12/31/1957

12

31

1957

myDate: 11/12/2015 test2Date: 02/29/1956 yourDate: 12/31/1957

Skeleton FOR Assignment#2

#include <iostream>

#include <iostring>

//#include "date.h"

using namespace std;

//*********************************************************************************************

//*********************************************************************************************

// D A T E . h

//This declaration should go in date.h

#ifndef DATE_H

#define DATE_H

class Date

{

public: Date(); //default constructor; sets m=01, d=01, y =0001 Date(unsigned m, unsigned d, unsigned y);

//explicit-value constructor to set date equal to today's

//date. Use 2-digits for month (m) and day (d), and 4-digits for year (y); this function should

//print a message if a leap year.

void display();//output Date object to the screen

int getMonth();//accessor to output the month

int getDay();//accessor to output the day

int getYear();//accessor to output the year

void setMonth(unsigned m);//mutator to change the month

void setDay(unsigned d);//mutator to change the day

void setYear(unsigned y);//mutation to change the year

friend ostream & operator<<(ostream & out, const Date & dateObj);//overloaded operator<< as a friend function with chaining

//you make add other functions if necessary

private:

int myMonth, myDay, myYear; //month, day, and year of a Date obj respectively };

#endif

//*********************************************************************************************

//*********************************************************************************************

// D A T E . C P P

//This stub (for now) should be implemented in date.cpp

//*************************************************************************************

//Name: Date

//Precondition: The state of the object (private data) has not been initialized

//Postcondition: The state has been initialized to today's date

//Description: This is the default constructor which will be called automatically when

//an object is declared. It will initialize the state of the class

//

//*************************************************************************************

Date::Date()

{

//the code for the default constructor goes here

}

//*************************************************************************************

//Name: Date

//Precondition:

//Postcondition:

//Description:

//

//

//*************************************************************************************

Date::Date(unsigned m, unsigned d, unsigned y)

{

}

//*************************************************************************************

//Name: Display

//Precondition:

//Postcondition:

//Description:

//

//

//*************************************************************************************

void Date::display()

{

}

//*************************************************************************************

//Name: getMonth

//Precondition:

//Postcondition:

//Description:

//

//

//*************************************************************************************

int Date::getMonth()

{

return 1;

}

//*************************************************************************************

//Name: getDay

//Precondition:

//Postcondition:

//Description:

//

//

//*************************************************************************************

int Date::getDay()

{

return 1;

}

//*************************************************************************************

//Name: getYear

//Precondition:

//Postcondition:

//Description:

//

//

//*************************************************************************************

int Date::getYear()

{

return 1;

}

//*************************************************************************************

//Name: setMonth

//Precondition:

//Postcondition:

//Description:

//

//

//*************************************************************************************

void Date::setMonth(unsigned m)

{

}

//*************************************************************************************

//Name: setDay

//Precondition:

//Postcondition:

//Description:

//

//

//*************************************************************************************

void Date::setDay(unsigned d)

{

}

//*************************************************************************************

//Name: getYear

//Precondition:

//Postcondition:

//Description:

//

//

//*************************************************************************************

void Date::setYear(unsigned y)

{

}

ostream & operator<<(ostream & out, const Date & dateObj)

{

return out;

}

//*********************************************************************************************

//*********************************************************************************************

// D A T E D R I V E R . C P P

//EXAMPLE OF PROGRAM HEADER

int main()

{

//Date myDate;

//Date yourDate(12,31, 1957);

//Date test1Date(15, 1, 1962);

//should generate error message that bad month

//Date test2Date(2, 29, 1956);

//ok, should say leep year

//Date test3Date(2, 30, 1956);

//should generate error message that bad day

//Date test4Date(12,31,0000);

//should generate error message that bad year

//Date test5Date(80,40,0000);

//should generate error message that bad month, day and year

//yourDate.display();

//cout<<yourDate.getMonth()<<endl;

//cout<<yourDate.getDay()<<endl;

//myDate.setMonth(11);

//myDate.setDay(12);

//myDate.setYear(2015);

//cout<<"myDate: "<<myDate<<" test2Date: "<<test2Date<<" yourDate: "<<yourDate<<endl;

return 0;

}

In: Computer Science

Visual Studio is an integrated development environment, which means that it combines an editor, compiler and...

Visual Studio is an integrated development environment, which means that it combines an editor, compiler and debugger into a single interface. When you work on Matrix, you have to edit your program in Visual Studio and then compile and test on Matrix using the gcc compiler. Which set of tools do you prefer for programming? What are the advantages of your preferred tool set over the alternative? What do you think would be the difficulties in learning to use the tool set you least prefer?

In: Computer Science

/* CIS 251 In Class Assignment    This program performs various operations on a ten element...

/*

CIS 251 In Class Assignment

  

This program performs various operations on a ten

element int array.

*/

#include <iostream>

using namespace std;

void start (int boxes [10]);

void move (int squares [10], int x, int y, int z);

void add (int arr [10], int first, int last);

void print (int arr [10]);

int main ()

{

int my_arr [10];

  

cout << "The original array is:\n";

print (my_arr);

  

start (my_arr);

cout << "\n\nThe array after start is:\n";

print (my_arr);

  

move (my_arr, 2, 4, 6);

cout << "\n\nThe array after move is:\n";

print (my_arr);

  

add (my_arr, 3, 7);

cout << "\n\nThe array after add is:\n";

print (my_arr);

  

cout << "\n\n";

return 0;

}

void start (int boxes [10])

{

   int index, count;

   count = 17;

   for (index = 0; index < 10; index++)

   {

   boxes [index] = count;

   count--;

   }

}

void move (int squares [10], int x, int y, int z)

{

   int temp;

   temp = squares [x];

   squares [x] = squares [y];

   squares [z] = squares [y];

   squares [y] = temp;

}

void add (int arr [10], int first, int last)

{

   int m;

   for (m = first; m <= last; m++)

   arr [m]++;

}

void print (int arr [10])

{

   int z;

   for (z = 0; z < 10; z++)

   cout << z << " ";

}

Questions and Experiments:

1. The function print is supposed to print each element of the array but does not work. What does it print?

  • Fix the print function so that it works properly.

2. Now that print has been fixed, run your program again. Why did “funny” values show up for the first call to print?

3. The array has different names in the functions than it does in main. Explain why this is not a problem.

4. Would the program still work if the array had the same name in the functions as in main?

5. What values would be placed in the array by the function start if count was initially set equal to 0 instead of 17? Show the values.

6. Remove the { } associated with the for statement in the function start. Run your program and explain clearly why the output changes as shown.

Add the {} back to the program.

7. Say that we have an array, my_arr, with the following values:

   5 9 3 4 6 12 19 22 3 4

[0] [1] [2] [3] [4] [5] [6] [7] [8] [9]

and the function move is called as follows:

move (my_arr, 1, 3, 5);

Show above how this call would change the array.

8. Explain clearly what the function add does. Include the parameters first and last in your explanation.

9. How would add change the array if called as follows:

add (my_arr, 7, 2);

Explain your answer.

  • Add a function prototype and definition for a function called print_reverse to your program. print_reverse takes an array as a parameter and prints the array values in reverse order. Have your program call this function after the last print. Have main print a label indicating that the array is being printed in reverse before the call.

In: Computer Science

Be sure to statically disable both the Enter Subtotal label and the Enter Subtotal textbox. If...

  1. Be sure to statically disable both the Enter Subtotal label and the Enter Subtotal textbox. If you do not know what this means, ask.
  2. Add a label, a text box, and an OK button (see Exercise 3.1 X if you need a refresher) to your form to enable the user to enter his or her name and click OK.

3. In the handler code for the OK button, first check (as you did in Exercise 1 X) to ensure that the name is not blank. If the name is blank generate a message as requested in Exercise 1 X, reset focus and have the user try again to enter a non-blank name.

4. Once a non-blank name has been entered, dynamically (in your own code) enable the Enter Subtotal label and the Enter Subtotal text box.

5. Now in your handler code for btnCalculate, insert try-catch code (see p. 193 for an example) to catch an invalid decimal value entry and ask the user to re-enter his or her data.  

6. Test your project and if the code you have added does not catch a negative input value, make sure you correct this problem and retest your project.

This is the code that I have.

namespace InvoiceTotal
{
   public partial class frmInvoiceTotal : Form
   {
public frmInvoiceTotal()
       {
           InitializeComponent();
       }

       int numberOfInvoices = 0;
       decimal totalOfInvoices = 0m;
       decimal invoiceAverage = 0m;
       decimal largestInvoice = 0m;
       decimal smallestInvoice = Decimal.MaxValue;

       private void btnCalculate_Click(object sender, EventArgs e)
       {
           decimal subtotal = Convert.ToDecimal(txtEnterSubtotal.Text);
           decimal discountPercent = .25m;
           decimal discountAmount = Math.Round(subtotal * discountPercent, 2);
           decimal invoiceTotal = subtotal - discountAmount;

           txtSubtotal.Text = subtotal.ToString("c");
           txtDiscountPercent.Text = discountPercent.ToString("p1");
           txtDiscountAmount.Text = discountAmount.ToString("c");
           txtTotal.Text = invoiceTotal.ToString("c");

           numberOfInvoices++;
           totalOfInvoices += invoiceTotal;
           invoiceAverage = totalOfInvoices / numberOfInvoices;
           largestInvoice = Math.Max(largestInvoice, invoiceTotal);
           smallestInvoice = Math.Min(smallestInvoice, invoiceTotal);

           txtNumberOfInvoices.Text = numberOfInvoices.ToString();
           txtTotalOfInvoices.Text = totalOfInvoices.ToString("c");
           txtInvoiceAverage.Text = invoiceAverage.ToString("c");
           txtLargestInvoice.Text = largestInvoice.ToString("c");
           txtSmallestInvoice.Text = smallestInvoice.ToString("c");

           txtEnterSubtotal.Text = "";
           txtEnterSubtotal.Focus();
       }

       private void btnClearTotals_Click(object sender, System.EventArgs e)
       {
           numberOfInvoices = 0;
           totalOfInvoices = 0m;
           invoiceAverage = 0m;
           largestInvoice = 0m;
           smallestInvoice = Decimal.MaxValue;

           txtNumberOfInvoices.Text = "";
           txtTotalOfInvoices.Text = "";
           txtInvoiceAverage.Text = "";
           txtLargestInvoice.Text = "";
           txtSmallestInvoice.Text = "";

           txtEnterSubtotal.Focus();
       }

       private void btnExit_Click(object sender, EventArgs e)
       {
           this.Close();
       }

   }
}

In: Computer Science

Write single linux commands for each question. 2. Find every file ends with “.py” or “.txt”...

Write single linux commands for each question.

2. Find every file ends with “.py” or “.txt” or “.cpp” from your root directory, and list the detail of each file.
3. Find every line that contains two or more space in every file in “Folder1” include subdirectory.
4. Find every line that contains two or more “<<” symbol in “Folder2” include subdirectory.
5. Find every line that contains parentheses inside parentheses in “Folder3” include subdirectory, such as print(type(6*2)).
6. Find every line that contains at least two digits in folder “Folder1”, “Folder2” and “Folder3” include subdirectory. The two digits can be two separate digit, such as “1.5” or “1 and 2”.
7. Find every line that start with “}” or ends with “{” in “Folder2” include subdirectory. Example: “int main(){” or “}”.
8. Find every line that contains any pair of repeated words in folder “Folder1”, “Folder2” and “Folder3” include subdirectory. Example: a + a, b b, c d c d. (The command should be able to find the ‘c = a + “ ” + b’)
9. List every filename contains at least two digits from folder “Folder1”, “Folder2” and “Folder3” include subdirectory.
10. List every filename contains a number that greater than 11 and less than 22 from folder “Folder1”, “Folder2” and “Folder3” include subdirectory.

In: Computer Science

What are design patterns in object oriented programming? Minimum 200 words

What are design patterns in object oriented programming?

Minimum 200 words

In: Computer Science

The biggest mysteries of the IEEE 754 Floating-Point Representation are “hidden bit” and “Bias. Can someone...

The biggest mysteries of the IEEE 754 Floating-Point Representation are “hidden bit” and “Bias.

Can someone explain to me why the "hidden bits" and "bias" are considered to be mysteries for the IEEE 754 floating point representation

In: Computer Science

Android Studio (Java) I'm trying to create a simple calculator. I want to put out a...

Android Studio (Java)

I'm trying to create a simple calculator. I want to put out a message if they try to divide by 0.

I have this so far. What code should I put?

divide.setOnClickListener(new View.OnClickListener() {
    @Override
    public void onClick(View view) {
        if (number1.getText().length() != 0 && number2.getText().length() != 0) {
            double n1= Double.parseDouble(number1.getText().toString());
            double n2= Double.parseDouble(number2.getText().toString());

            double res= n1 / n2;

            result.setText(String.valueOf(res));
        } else {
            Toast.makeText(view.getContext(), "Please enter the numbers properly", Toast.LENGTH_SHORT).show();
        }
    }

});

In: Computer Science

There are issue the muy code The Body Mass Index (BMI) is a calculation used to...

There are issue the muy code

The Body Mass Index (BMI) is a calculation used to categorize whether a person’s weight is at a healthy weight for a given height. The formula is as follows:

                bmi = kilograms / (meters2)

                where kilograms = person’s weight in kilograms, meters = person’s height in meters

BMI is then categorized as follows:

Classification

BMI Range

Underweight

Less than 18.5

Normal

18.5 or more, but less than 25.0

Overweight

25.0 or more, but less than 30.0

Obese

30.0 or more

To convert inches to meters:

                meters = inches / 39.37

To convert pounds (lbs) to kilograms:

                kilograms = lbs / 2.2046

Assignment

Ask the user for their weight in pounds and height in inches. Compute their BMI and BMI classification and output the results.

The program must implement and use the following methods:

convertToKilograms – convert pounds to kilograms

convertToMeters – convert inches to meters

calcBMI – take weight in kilograms and height in meters and return the BMI

bmiClassification – take the value for the BMI and return a String with the BMI classification

Use the following code as a starting point for your assignment:

import java.util.Scanner;

// TODO Student name, date, purpose
public class Main {

    private static Scanner input = new Scanner(System.in);

    public static void main(String[] args) {
        double lbs, inches, meters, kgs, bmi;
        String classification;

       // TODO add code here
   
}

   // TODO add your methods here (make them static)
}

As always use the package name edu.cscc and include a comment with your name, the date, and the purpose of the program.

Example Output

Calculate BMI

Enter weight (lbs): 200

Enter height (inches): 72

Your BMI is 27.124767811523153

Your BMI classification is Overweight

My code:

public class Main {

    private static Scanner input = new Scanner(System.in);

    public static void main(String[] args) {
        double lbs, inches, meters, kgs, bmi;
        String classification;
        System.out.println("Calculate BMI");
        System.out.println("Enter weight(lbs):");
        lbs = input.nextDouble();
        System.out.println("Enter height (inches):");
        meters = input.nextDouble() * 0.0254;
        //Converting pounds to kegs
        kgs = lbs / 2.2;
        //Calculation of BMI
        bmi = calculateBMI(kgs, meters);
        //Classification of bmi
        classification = classify(bmi);
        System.out.println("Your BMI is " + bmi);
        System.out.println("Your BMI classification is " + classification);
    }

    public static double calculateBMI(double weight,double height) {
        return weight/ (height*height);
    }
    // Classify the BMI to string
    public static String classify(double bmi) {
        if(bmi < 18.5) {
            return "Underweight";
        }else if(bmi < 25.0) {
            return "Normal";
        }else if(bmi < 30.0) {
            return "Overweight";
        }else {
            return "Obese";
        }
    }
}

In: Computer Science

Cyber security Security Policy: , write a small antivirus policy for the IT infrastructure and users...

Cyber security

Security Policy:

  1. , write a small antivirus policy for the IT infrastructure and users in a
    1. small business
    2. an elementary school
    3. You may research anti-virus policies of organizations on the web, please use and cite responsibly.

Security Recommendation: Rose Shumba manages the IT security for a school. Given the wide range of people who use the school’s computers, it is challenging for Rose to prevent virus infections. She has installed an anti-virus on each machine and has a policy prohibiting software downloads.

Comment on:

  1. How secure is the network from viruses?
  2. What areas has Rose not secured?
  3. What recommendations would you make to Rose to increase the security?

In: Computer Science

In C++, Write the following program using a vector: A common game is the lottery card....

In C++, Write the following program using a vector:

A common game is the lottery card. The card has numbered spots of which a certain number are selected at random. Write a Lotto() function that takes two arguments. The first should be the number of spots on a lottery card and the second should be the number of spots selected at random. The function should return a vector object that contains, in sorted order, the numbers selected at random. Use your function as follows:

Vector winners;

winners = Lotto(51,6);

This would assign to winners a vector that contains six numbers selected randomly from the range 1 through 51.

Also write a short program that lets you test the function,

In: Computer Science

Using Visual Studio in C#; create a grading application for a class of ten students. The...

Using Visual Studio in C#; create a grading application for a class of ten students. The application should request the names of the students in the class. Students take three exams worth 100 points each in the class. The application should receive the grades for each student and calculate the student’s average exam grade. According to the average, the application should display the student’s name and the letter grade for the class using the grading scheme below. Grading Scheme: • A = 90-100 • B = 80-89 • C = 70-79 • D = 60-69 • F = <60

In: Computer Science

Question: In a package named "oop" create a Scala class named "Team" and a Scala object...

Question: In a package named "oop" create a Scala class named "Team" and a Scala object named "Referee". Team will have:

• State values of type Int representing the strength of the team's offense and defense with a constructor to set these values. The parameters for the constructor should be offense then defense

• A third state variable named "score" of type Int that is not in the constructor, is declared as a var, and is initialized to 0 Referee will have:

• A method named "playGame" that takes two Team objects as parameters and return type Unit. This method will alter the state of each input Team by setting their scores equal to their offense minus the other Team's defense. If a Team's offense is less than the other Team's defense their score should be 0 (no negative scores)

• A method named "declareWinner" that takes two Teams as parameters and returns the Team with the higher score. If both Teams have the same score, return a new Team object with offense and defense both set to 0

In: Computer Science

In this assignment, you will write a class that implements a contact book entry. For example,...

In this assignment, you will write a class that implements a contact book entry. For example, my iPhone (and pretty much any smartphone) has a contacts list app that allows you to store information about your friends, colleagues, and businesses. In later assignments, you will have to implement this type of app (as a command line program, of course.) For now, you will just have to implement the building blocks for this app, namely, the Contact class.
Your Contact class should have the following private data:
• The first name of the person
• The last name of the person •The phone number of the person • The street address of the person • The city of the person
• The state of the person
The Contact class should implement the Comparable interface. More on this later.
Of course, you may implement private helper methods if it helps your implementation.
Your class should have the following public methods:
• A constructor that initializes all the fields with information.
• A constructor that initializes only the name and phone number.
• accessor (getter) methods for all of the data members.
• an update method that allows the user to change all information. (They must change all of it).
• An overridden equals() method that can tell if one Contact is the same as another. It should have the method signature:
public boolean equals(Object obj);
We will define one Contact as being the same as another contact if the first and last names both match. (Be careful! The parameter may not be a bona fide Contact!)
• An overridden toString() method that creates a printable representation for a Contact object.
  
It should have the method signature:
public String toString();
The String should be created in the following form:
<First name> <last name> Phone number: <phone number> <street address>
<city> , <state>
For example my contact info would look like:
john Doe Phone number: (111) 111-1111
2900 XYZ Avenue
city, state
• A comparison method that looks like this:
public int compareTo(Contact another);
We will define this method in the following way:
If the last name of “another” is lexicographically first, return a positive
number.
If the last name of “another” is lexicographically second, return a negative
number.
If the last names are the same and the first names are also the same, return 0. If the last names are the same and the first names are different, use the first
names to determine the order.
You must also declare the fact that Contact implements the Comparable interface.
You must also write a main program that tests each of these functions and
shows me that you understand how to use the Contact class in a program.
You can choose to write this main program as a stand alone class that sits in the same directory as the Contact class, or you can just make the main program the main program of the Contact class itself.

In: Computer Science