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
Mila [183]
3 years ago
7

The following algorithm adds all the entries in a square n × n array A. Analyze this algorithm where the work unit is the additi

on operation. sum = 0 for i = 1 to n do for j = 1 to n do sum = sum + A[i, j] end for end for write ("Total of all array elements is", sum)

Computers and Technology
1 answer:
wlad13 [49]3 years ago
6 0

Answer:

T(n)=n(n+1)/2

Explanation:

See the attached picture for detailed explanation.

You might be interested in
When you hear the word “stress” what does it mean to you? How does stress affect you and what do you do to cope with stress
stepan [7]

   Ways to Cope with  Stress

  • Re-balance Work and Home.
  • Build in Regular Exercise.
  • Eat Well and drink lots of water.
  • Connect with Supportive People.
  • Carve out Hobby Time.
  • Practice Meditation, Stress Reduction or Yoga.
  • Sleep Enough.
  • Bond with Your Pet.

 

hope it helps! :)

3 0
3 years ago
Write a C++ program to exchange values of two variables using function exchange().
Shkiper50 [21]

Answer:

#include<iostream>

using namespace std;

//create the exchange function

void exchange(int a, int b){

   int temp;  //initialize temporary

   //swap the variables value

   temp=a;

   a=b;

   b=temp;

   //print the output after exchange

   cout<<"a is: "<<a<<endl;

   cout<<"b is: "<<b<<endl;

}

//main function program start from here

int main(){

  //initialization

  int a=3, b=6;

  exchange(a,b);  //calling the function

  return 0;

}

Explanation:

Create the function exchange with two integer parameter which takes the value from the calling function.

and then declare the third variable temp with is used for swapping the value between two variables.

first store the value of 'a' in the temp and then assign the 'b' value to 'a' and then, assign the temp value to b.

for example;

a=2, b=9

temp=2;

a=9;

b=2;

So, the values are swap.  

and then print the swap values.

Create the main function and define the input a and b with values.

Then, calling the exchange function with two arguments.

6 0
3 years ago
What is the potential outcome for an author if she uses a word without realizing its connotation? she may write something that s
zubka84 [21]

A potential outcome for an author who uses a word without realizing its connotation is: A. she may write something that she does not mean.

<h3>What is connotation?</h3>

Connotation refers to the quality, feeling or an idea which a word brings to the mind of a reader or listener, as well as its literal, dictionary or primary meaning.

This ultimately implies that, a potential outcome for an author who uses a word without realizing its connotation is that he or she may write something that she does not mean or pass across an information she didn't intend to.

Read more on connotation here: brainly.com/question/20236939

#SPJ1

3 0
2 years ago
Please Help ASAP. Marking Brainliest For Correct Answer.
mezya [45]

Answer: It is not working because it is missing the code needed to turn right.

Sentence :The robot would move forward two squares and would stay stuck there because it can not move forward nor turn left. You would need to add code for the robot to be able to turn right so that the robot can reach the goal

6 0
3 years ago
What can you do in the Mouse section of the Devices and Printers menu?
ANTONII [103]
See for yourself.
On windows hit windowskey+r
Type in control and then hit enter
Then search device and printers

The answer is you can add an change settings (dpi, color) of the mouse
3 0
3 years ago
Other questions:
  • What type of graphic organizer will help jane compare the results of a student survey about teachers at her school?
    15·2 answers
  • It is important that data being imported from a text file into access are separated by a character, such as a comma, which defin
    8·1 answer
  • What term is used to describe the time it takes a signal to travel from one location to another on a network?
    13·1 answer
  • The most common types of utility programs fall into these categories. accessibility calculation communication data entry enterta
    6·2 answers
  • Which of the following savings vehicles usually requires a high minimum balance?
    12·1 answer
  • Baris script yang digunakan mendefinisikan website yang akan diblokir proxy server adalah
    5·1 answer
  • How is digital footprint created ?
    15·1 answer
  • The Electronic Communications Privacy Act requires an investigator to have a wiretap order to acquire ___________ information fr
    8·1 answer
  • Question 7 (1 point)<br> Increasing hue levels means increasing saturation.<br> True<br> False
    11·1 answer
  • True or false. The CPU requires it's own power from the power supply, and can't receive power from the motherboard.
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!