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
kvasek [131]
3 years ago
9

The following code accomplishes which of the tasks written below? Assume list is an int array that stores positive int values on

ly. int foo = 0; for (int j =0 ; j < list.length; j++) if (list[j] > foo) foo = list[j];
Computers and Technology
1 answer:
liq [111]3 years ago
6 0

Answer:

It stores the largest value in list (the maximum) in the variable 'foo'.

Explanation:

<u>Following are the description of the answer</u>:

In the above code, they set and initialize the integer data type variable that is 'foo' to 0. Then, they set the for loop that iterates from 0 and end at length of the list. Then, they check the condition, if the list of j i.e., list[j] is greater than the variable 'foo', then the value of the list[j] stored in the variable 'foo'.

So, if the value of the list[j] is greater than 0, then the value of the list[j] is initialized in the variable 'foo'. That's why it stores the largest value.

You might be interested in
Select each of the tasks that you could complete using a word processor.
Korolek [52]

Answer:

  • Create a table that lists your favorite movies and actors
  • Write a manuscript of a book
  • Make a list of homework assignments

Explanation:

Word processing tool is used for different purposes such as typing reports, preparing notes and books etc.

Now from the given options, following tasks can be performed using a word processor

  • Create a table that lists your favorite movies and actors
  • Write a manuscript of a book
  • Make a list of homework assignments
4 0
3 years ago
Read 2 more answers
A call center company wants to implement a domain policy primarily for its shift workers. The call center has large groups with
Ulleksa [173]

Answer:

D) Time-of-day restrictions

Explanation:

Based on the goals that the call center company is trying to accomplish it can be said that the best solution would be to implement Time-of-day restrictions. This would mean that only certain groups would be active at specific times during the day, thus allowing the company to focus on each group individually in order to monitor their group performance.

3 0
4 years ago
You are capturing packets with a network sniffer and notice a number of packets that are flagged by the sniffer and described as
Rom4ik [11]

Answer:

Transport Layer                                    

Explanation:

  • Transport layer is responsible for correcting data transmission errors which is done by requesting retries also called re-transmission of packets in case of data loss or corrupted data.
  • Transport layer ensures end to end delivery of data making sure that the data is received correctly and in same order in which it was sent.
  • Transmission Control Protocol (TCP) is a protocol in this layer that continues to transmit data packets securely from sender to receiver, identifying packet losses.
  • Transport layer works on packet loss issues and corrects data transmission errors.
  • It has flow control and error control services manage data transmission rate and ensures data is received without error.
  • So in case of transmission errors and re-transmission requests transport layer should be investigated.
5 0
3 years ago
"Currency" is a field data type ,it represents Date or time values<br> True or false tho?
trapecia [35]

Answer:

true

Explanation:

6 0
3 years ago
What type of stone was the most common building material of royal pyramid?
eimsori [14]
I think it's low grade lime stone..
6 0
3 years ago
Other questions:
  • A broadcast network is one in which a transmission from any one attached station is received by all other attached stations over
    10·1 answer
  • Write a function called matches that takes two int arrays and their respective sizes, and returns the number of consecutive valu
    6·1 answer
  • Problem 3. Consider the following recurrence, defined for n a power of 4 (for the time of some algorithm): T(n) = 3 if n = 1 2T(
    5·1 answer
  • marco wants to create a heading that is bold and italic to make it really stand out on his webpage. he's typed in the code
    12·2 answers
  • An attacker is intent on disturbing the communication by inserting bogus packets into the communications.
    9·1 answer
  • Ple Choice Worth 5 points)
    11·1 answer
  • Instruction: weird I know (~ ̄³ ̄)~
    5·1 answer
  • Your friends are having difficulties with their computer setups. Can you suggest a way to help each friend?
    5·1 answer
  • Which cyber protection condition establishes a protection.
    12·1 answer
  • In python, what is the difference between a dictionary and a set? How are they similar?
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!