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
tangare [24]
3 years ago
8

Lists and Procedures Pseudocode Practice For each situation, provide a pseudocoded algorithm that would accomplish the task. Mak

e sure to indent where appropriate. Situation A Write a program that: Takes the list lotsOfNumbers and uses a loop to find the sum of all of the odd numbers in the list (hint: use Mod). Displays the sum. Situation B Write a procedure that takes
Computers and Technology
1 answer:
Andrei [34K]3 years ago
6 0

Answer:

The pseudocoded algorithm is as follows:

Procedure sumOdd(lotsOfNumbers):

    oddSum = 0

    len = length(lotsOfNumbers)

    for i = 0 to len - 1

         if lotsOfNumbers[i] Mod 2 != 0:

              OddSum = OddSum + lotsOfNumbers[i]

Print(OddSum)

Explanation:

This defines the procedure

Procedure sumOdd(lotsOfNumbers):

This initializes the oddSum to 0

    oddSum = 0

This calculates the length of the list

    len = length(lotsOfNumbers)

This iterates through the list

    for i = 0 to len-1

This checks if current list item is odd

         if lotsOfNumbers[i] Mod 2 != 0:

If yes, the number is added to OddSum

              OddSum = OddSum + lotsOfNumbers[i]

This prints the calculated sum

Print(OddSum)

You might be interested in
Demonstrate the register addressing mode for the following instructions. Also what addressing mode belongs to these instructions
kotykmax [81]

Answer:

Demonstrate the register addressing mode for the following instructions. Also what addressing mode belongs to these instructions?

1. MOV CX, [BX+DI]

2. MOV AX, ARRAY[CX]

3. MOV BX, [CX+DI+6]

4 0
3 years ago
What are the elements of an autobiographical narrative similar to those of a short story?
sattari [20]
A. because the form is about stories from events in a writer's life
6 0
3 years ago
What is the following file format called? inv_nbr, inv_name, inv_cost 876521,battery,45.00
kiruha [24]

The  following file format of  inv_nbr, inv_name, inv_cost is called delimited format.

<h3>What is a delimited file in Excel?</h3>

The term "Delimited" is known to be a term that connote a form of  an  TXT file that tends to make use of tabs or an  CSV file that uses commas to  be able to separate and group your data.

Note also that a  delimited file is seen as a form of a given sequential file that is made up of column delimiters.

Therefore, The  following file format of  inv_nbr, inv_name, inv_cost is called delimited format.

Learn more about text format from

brainly.com/question/16397886

#SPJ1

Multiple Choice

fixed-width format

extensible markup

delimited format

hypertext format

6 0
1 year ago
What are the guided and unguided transmission media and what are the differences?
Ludmilka [50]

Answer:  They are forms of of carrying data from communication devices. The difference is the medium where the signal travels.

Explanation:

Hi, the difference between guided and unguided media is that in the guided media, the signal travels through a physical medium whereas, in unguided media, the signal travels through the air.  

Guided and unguided media are types of transmission media.

The transmission media carries electromagnetic signals, that transmit data between communicating devices like computers.

4 0
3 years ago
Your company has merged with another company that also uses Windows Server 2016 and Active Directory. You want to give the other
LiRa [457]

Answer:Creation of two-way forest trust

Explanation: In active directory, Two way forest trusty is the two way trusting condition where one forest trust the other forest and it works same for both forest.The forest domain of one forest is reliable and have trusty relationship with the other forest and vice-versa.

This function of the forest helps all the users to reliably access all the components of both the domains.Thus two-way forest trust should be created between the two organization mentioned in the question.

5 0
3 years ago
Other questions:
  • ____ are systems in which queues of objects are waiting to be served by various servers
    5·1 answer
  • PLEASE HELPP!! WILL MARK BRAINLIEST!!~~~~~
    11·1 answer
  • Another html/css assignment, drop css code below, thank you
    15·1 answer
  • Which is the biggest known issue specific to satellite Internet connections?
    13·2 answers
  • What is an Apple Pen?
    5·2 answers
  • What is a benefit of the rise in citizen journalism? Multiple answer choice below
    13·1 answer
  • Ok so I usually don’t do this but I just need an answer , on Instagram a notification popped up while I was watching someone’s s
    9·2 answers
  • PLZ HELP What will be the output? class num: def init (self.a): self. number = a mul* __(self. b) return self. number + b. numbe
    7·1 answer
  • What are your thoughts on copyright?<br><br> (Write 2 or more sentences)
    9·2 answers
  • The __________ statement allows you to check for
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!