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
Match the expenses to their respective categories.
satela [25.4K]
Lambo , vacation and lavish weddings in want the other two in needs
4 0
3 years ago
Read 2 more answers
What type of object can offer the most effective way to display data and calculations in a presentation?
poizon [28]

This is definitely an opinion, but an excel you can do A and D and just about the same as B also

<u>So i'd say C </u>

8 0
3 years ago
What is one advantage of using the sharing tab vs. the security tab to give out permissions?
Hoochie [10]

Answer:

Depending on what operating system you have my best choice would be D since on some folders you can share permissions with other people. It really depends on what computer you're talking about.  

8 0
4 years ago
Suppose there are two ISPs providing WiFi service in a café. Each ISP operates its own AP and has its own IP address block. If b
Alinara [238K]

Answer:

As a design rule, access points within range of each other should be set to channel frequencies with minimal signal overlap. Users will find that roaming doesn’t work well, and performance will degrade because of interference between access points.

Explanation:

8 0
4 years ago
(Display nonduplicate words in ascending order)
olya-2409 [2.1K]

Answer:

The program to this question as follows:

Program:  

value = input("Input text value: ") #defining variable value and input value by user

word = value.split() #defining variable word that split value

sort_word = sorted(word) #defining variable using sorted function

unique_word = [] #defining list

for word in sort_word: #loop for matching same value

   if word not in unique_word: #checking value

       unique_word.append(word) #arrange value using append function

print(' '.join(unique_word)) #print value

Output:

Input text value: Good morning Good afternoon Good evening

Good afternoon evening morning  

Explanation:

In the above python code, a value variable is defined that uses input function to input value from the user end, and the word variable is declared, which uses the split method, which split all string values and defines the sort_word method that sorted value in ascending order.

  • Then an empty list "unique_word" is defined, which uses the for loop and inside the loop, a conditional statement is used.
  • In if block, it matches all value is unique if this is condition is true it will arrange all values and uses the print function to print all value.  

5 0
3 years ago
Other questions:
  • If you have a list of words that you wish me to make into a bulleted list, you must first highlig or ______ The words with the c
    13·1 answer
  • which one of these steps describe saving a newly created file. click on the save icon. minimize the file. name the file. select
    12·2 answers
  • This term describes two or more arrays that hold related data, and the related elements in each array are accessed with a common
    15·1 answer
  • In which of the following situations should you expect to provide your Social Security number?
    13·1 answer
  • Given coins of denominations (value) 1 = v1 &lt; v2&lt; … &lt; vn, we wish to make change for an amount A using as few coins as
    11·1 answer
  • What can be designed to create annoying glitches or destroy data
    11·1 answer
  • When you're working with a word processing document and you press the DEL Key what happens
    7·2 answers
  • What technique involves graphical methods and nontechnical language that represent the system at various stages of development a
    14·1 answer
  • Which type of password would be considered secure
    5·2 answers
  • You are writing a program to help compare two sports teams. A sample member of the list scores is [2. 5] where your team scored
    5·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!