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
Novosadov [1.4K]
2 years ago
7

Your team at amazon is overseeing the design of a new high-efficiency data center at hq2. a power grid need to be generated for

supplying power to n servers. all servers in the grid have to be connected such that they have access to power. the cost of connections between different servers varies. assume that there are no ties, names of servers are unique, connections are directionless, there is at most one connection between a pair of servers, all costs are greater than zero, and a server does not connect to itself. write an algorithm to minimize the cost of connecting all servers in the power grid. input two arguments - num, an integer representing number of connections. connectons, representing a list of connections where each element of the list consists of two servers and the cost of connection between the servers. note: the cost of connection between the servers is always greater than 0.
example input num = 5 connection = [[a,b,1], [b,c,4], [b,d,6], [d,e,5], [c,e,1]]

output [[a,b,1], [b,c,4], [c,e,1], [d,e,5]]
Computers and Technology
1 answer:
elixir [45]2 years ago
3 0

Answer:

void print2(int row) {

for (int i = 0; i < row; i++) {

 char ch = 'a';

 char print = ch;

 for (int j = 0; j <= i; j++) {

  cout << print++;

 }

 cout << endl;

}

}

int count_digits(int num) {

int count = 0;

int temp = num;

while (temp != 0) {

 temp = temp / 10;

 count++;

}

return (num % count);

}

Explanation:

You might be interested in
What should you do if the drive on which you want to install windows server 2012 already has a partition on it containing an ope
Alinara [238K]
Delete those partitions and reformat the drive.
4 0
3 years ago
What component can be used for user input or display of output?
kogti [31]

Answer:

JTextField

Explanation:

JTextField is a Swing control which can be used for user input or display of output. It corresponds to a textfield and can be included with other controls such as JLabel, JButton,JList etc. on a comprehensive user interface which is application dependent. JTextField supports a read-write mode where the user can enter a value and it also supports a read-only mode which can be used to display non-editable output to the user.

4 0
3 years ago
If you’re the victim of cyber bullying behavior, besides contacting your teacher or the school, where else can you go to find in
RideAnS [48]

parents

childline

ceop

family

3 0
3 years ago
Do you play combat kite ?
nevsk [136]

Answer:

nah

Explanation:

7 0
3 years ago
Define the _make method, which takes one iterable argument (and no self argument: the purpose of _make is to make a new object;
Ksenya-84 [330]
This picture will show you the answer and guide the way to victory

7 0
2 years ago
Other questions:
  • The name of the opening that lets light into any camera is called ________.
    11·2 answers
  • You are building a gaming computer and you want to install a dedicated graphics card that has a fast gpu and 1gb of memory onboa
    15·2 answers
  • What time does walmart deposit paychecks?
    5·1 answer
  • What happens if i unplug my alarm system?
    11·1 answer
  • Problem 1: you must write a method for this problem called sentenceAnalyzer Write a program that reads a sentence from the keybo
    10·1 answer
  • Can you be my friend plz
    9·1 answer
  • BRAINLIEST!!! 20 PNTS!!!! HELPP!!!
    12·1 answer
  • The following is a training dataset that has ten one dimensional objects.
    12·1 answer
  • Tres areas donde se aplica la ciencia y tecnologia
    15·1 answer
  • Source ________ contains instructions written by a programmer specifying the actions to be performed by computer software.
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!