pernellmar7834 pernellmar7834
  • 18-01-2021
  • Computers and Technology
contestada

When defining a class, it is a best practice to declare ____ as private. constructors mutators nothing should be private accessors variables

Respuesta :

codiepienagoya codiepienagoya
  • 22-01-2021

Answer:

The answer is "variables".

Explanation:

It is necessary to declare a variable privately when declaring a class because the private variable 'protects' the code while it is in operation. It may not aim to protect it at this stage from changing the codes themselves for other developers. Its purpose of the so-called "data hiding" is to hold the internal data from many other classes using the class protected.

Answer Link

Otras preguntas

How do you think media affected the Emmit Till case? How would things have been different had there not been a magazine, newspaper, and television coverage of t
When washing items in the detergent solution when do you replace the water.
how many grams of carbon are 12 × 10^23 atoms of carbon?A. 2B. 6C. 1D. 24​
Solve the inequality. p ÷ 7 ≥ -4
How do you solve for these ? i need help pls
The number of individuals examined in an experiment is called the.
MAth pls help tysm :)
If a runner jogs 6 miles west and then jogs 3 miles north, how far is the runner from her starting point if she plans to run straight back
Which of the following is an example of specialization? a. general practitioner b. hospital c. pediatrics d. organization
Solve for x in the diagram below.