1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
ss7ja [257]
3 years ago
10

Write the definition of a class employee base on the modular specification: . A data member for Id of type int (private). A data

member for EmpName of type string (private). A data member for Salary of type double (private). A method to display the fields Id, EmpName, and Salary.
Computers and Technology
1 answer:
djyliett [7]3 years ago
7 0

Answer:

public class Employee {

   private int id;

   private String empName;

   private double salary;

   

   public void displayEmployee(){

       System.out.print("Employee ID: " + id + "\nEmployee name: " + empName + "\nSalary: " + salary);

   }

}

Explanation:

- Declare the class variables

- Write a method called <em>displayEmployee</em> to display the fields

You might be interested in
If you interview a dentist to learn about her experiences on the job, she is considered a secondary source of information. Pleas
Alik [6]

A source can be either primary or secondary. The statement that if you interview a dentist to learn about her experiences on the job, she is considered a secondary source of information is false. A primary source provides direct or firsthand  experience, while a secondary source of information describes or analyzes the primary source. In this case, when the dentist is interviewed she is considered as primary source because she is speaking about herself and her experience.


6 0
3 years ago
Read 2 more answers
Processors for most mobile devices run at a slower speed than a processor in a desktop PC.
kramer

Answer:

True....................

5 0
2 years ago
Read 2 more answers
write a function that takes two integer arrays as input return true if any two of the numbers in the first array input add up to
Afina-wow [57]

Answer:

Explanation:

This program is written in Python. It is a function that takes in two arrays. Then it loops through the first array twice, adding each element with the others and comparing the sum to the values in the second array. If a similar value is found in the second array, the program prints out the value and returns True to the user. Otherwise, it returns False. A test case has been created with two array variables that print out False, the output can be seen in the attached image below.

def sumArray(arr1, arr2):

   for i in range(len(arr1)):

       for x in range(len(arr1)):

           sum = 0

           if i != x:

               sum = arr1[i] + arr1[x]

           if sum in arr2:

               print(str(sum) + "Found in Second Array")

               return True

   return False

arr1 = [1, 9, 10, 44]

arr2 = [2, 4, 8, 14]

print(sumArray(arr1, arr2))

8 0
3 years ago
PLEASE HELP !!!! WILL UPVOTE
Gemiola [76]
The answer to this is C :D
5 0
2 years ago
Read 2 more answers
Why are people's visions of utopias and dystopias subjective?
Leno4ka [110]

Answer:

D. Because the technology needed for one person's utopia may be what creates disaster for another person's dystopia.

Explanation:

3 0
2 years ago
Other questions:
  • When called upon to give an impromptu speech, it is a good idea to do all of the following, except:
    11·2 answers
  • The set of communications rules for exchanging information electronically on the internet is called the ________.
    10·1 answer
  • Please answer this a due tomorrow!!!
    5·1 answer
  • Which of the following attributes of a website indicates a more reliable source for information?
    8·1 answer
  • which statement draws an accurate comparison between social media marketing and conventional marketing?
    13·1 answer
  • The __________ assumption necessary for a linear programming model to be appropriate means that the contribution to the objectiv
    6·1 answer
  • Plain text and ASCII text are the same thing. true or false
    12·1 answer
  • I can't solve this <br> Python loop with while statement
    15·2 answers
  • Computer network reduces the cost of operation​
    14·1 answer
  • How to transfer mysql database from one server to another
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!