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
Lelu [443]
4 years ago
9

Why should you use a named constant for the size of an array?

Computers and Technology
1 answer:
Brut [27]4 years ago
3 0
I can think of the following reasons:

- Avoid magic numbers. The constant will have a descriptive name like "MAX_MEASUREMENTS" so it can be inferred what the array size really means.

- Avoid duplication. There could be some related code (e.g., code that checks if an index is within the array bounds) that can benefit from using the same constant. Then it makes sense to tie them together such that if you change the constant, you're actually changing all its occurrances.

- Central configuration. By placing all your constants in a centralized place in the code, it is clear to see where your configuration resides. This is easier than having magic numbers scattered throughout the code.
You might be interested in
How are most gamepads installed on devices?
Doss [256]

Answer:

Plug and Play

Explanation:

most modern game pads are you just need to plug into a port and then you are free to use without any setting up.

3 0
3 years ago
Explain how communication promotes cooperation and industrial peace​
tensa zangetsu [6.8K]

Explanation:

Communication helps the management to know what the organisation wants and how it can be performed. Through effective way of communication it promotes the industrial peace and good relations. 7. ... It enables the management to take managerial decisions which depends upon the quality of communication.

4 0
3 years ago
░▒▓█►─═ ℍᵒ ═─◄█▓▒░ (っ◔◡◔)っ ♥ how are you doing ♥
Lera25 [3.4K]
I’m not doing too hot
Stressing over school and I doesn’t help that I don’t understand somethings
8 0
3 years ago
A system administrator is selecting an operating system for use by the company’s research and development team. The team require
kobusy [5.1K]

Answer:

C. Linux (open source)

Explanation:

Characteristics operating systems Linux:

  • Its modular structure allows modifying some of its elements to fit the needs of the user.
  • It's free
  • It is powerful, safe and stable.
  • It is multi-user and multi-tasking system.
  • There are countless programs for any type of task you want to develop.
  • memory protection between processes.
8 0
3 years ago
Which of the following is a property of TCP?
Serggg [28]

Answer:

o best effort

Explanation:

beacuse it i think do

3 0
3 years ago
Other questions:
  • A measure of the processing power of a computer
    6·1 answer
  • Systems thinking includes consideration of all of the following EXCEPT
    9·1 answer
  • In computer science, what are two names that are used to describe data structures organized by association
    6·1 answer
  • In the context of a global information system (GIS), _____ networks offer electronic data interchange standards, encryption, sec
    10·1 answer
  • A company accidentally sends a newsletter with a mistyped website address. The address points to a website that has been spoofed
    8·1 answer
  • Computers help eliminate that repetitive of manual task. How can this benefit you in in your overall career
    7·2 answers
  • Which is an example of an input device?
    6·2 answers
  • Edhesive code practice 6.3
    14·2 answers
  • An employee is working on building a new computer application for a friend. For this purpose, he uses the software that is regis
    5·1 answer
  • True or Fale A criminal defense attorney's main focus is to convict the accused of a crime, and a state prosecutor is to defend
    12·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!