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
ladessa [460]
3 years ago
12

Write an if/else statement that adds 1 to the variable minors if the variable age is less than 18, adds 1 to the variable adults

if age is 18 through 64, and adds 1 to the variable seniors if age is 65 or older.
Computers and Technology
1 answer:
Mama L [17]3 years ago
6 0

Answer:

Explanation:

data is a statement like

data 10,20, 30 , 40 , 50, 60 , 70, 80

\\the numbers represent ages.

For x := 1 to end of data do a[x]:=read(data)

\\ This is a comment. You could do this much easier if you just use three if statements rather than the if then else.

minor:=0;adult:=0;senior:=0;

while a[x] <> 0 do begin

age:= a[x]

if age < 19 then minor:=minor + 1;

If age > 18 then if age < 65 the adult:=adult + 1;

if age > 64 then senior := senior + 1;

end;

I have not declared the variables anywhere. That depends on what language you are using. The key step you  want are the three if statements. How you find out what's in them is another matter.

You might be interested in
What are the 7 c s of communication​
Hatshy [7]

Answer: the answer is A.

Explanation: hope this helps!

5 0
3 years ago
What is a computer system?
klio [65]
A system of interconnected computers that share a central storage system and various peripheral devices such as a printers, scanners, or routers. Each computer connected to the system can operate independently, but has the ability to communicate with other external devices and computers

<span>Read more: http://www.businessdictionary.com/definition/computer-system.html</span>
4 0
3 years ago
What are some cowboy ethics??
lys-0071 [83]

Answer:

giv meh a min plsssss

Explanation:

4 0
3 years ago
Juan has performed a search on his inbox and would like to ensure that the results only include those items with
lubasha [3.4K]

Answer:

The Refine command group

Explanation:

8 0
3 years ago
Select below the Active Directory server role that provides the functions of Active Directory without the requirements of forest
sasho [114]

Answer:

​AD DS

Explanation:

Active Directory Domain Service is an active directory server role found in windows server and it permits admins in a network environment store and also manages information from a particular source in a network, there are no requirements for forests, domains, and domain controllers. It works both on intranet and internet networks.

3 0
4 years ago
Other questions:
  • Create a procedure named FindLargest that receives two parameters: a pointer to a signed doubleword array, and a count of the ar
    13·1 answer
  • 2.24 Write the relevant Python expression or statement, involving a list of numbers lst and using list operators and methods for
    11·1 answer
  • Which statement best describes a transition in PowerPoint?
    12·1 answer
  • 13 POINTS! Which option is used to ensure the integrity and authenticity of a Word document but requires additional services to
    6·2 answers
  • Which software development team memeber is responsible for the timeline and budget
    9·1 answer
  • You must. place a child in a federally approved child restraint device. if the child is
    5·2 answers
  • Pixar is a company that creates a huge amount of images, audio recordings, and videos, and they need to decide what compression
    11·1 answer
  • The core of ___________ is the implementation of intrusion detection systems and intrusion prevention systems at entry points to
    8·1 answer
  • Identify the programmer’s responsibility in maximizing the programs reliability by having awareness of the beneficial and harmfu
    8·1 answer
  • A(n) ______is like an intranet except it shares its resources with users from a distant location. Select your answer, then click
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!