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
postnew [5]
3 years ago
12

Write a function namedmake_complex that stores its twoarguments (both of type double) in acomplex structure, then returns thestr

ucture.
Computers and Technology
1 answer:
valentina_108 [34]3 years ago
3 0

Answer:

#include <iostream>

using namespace std;

struct complex{//structure of comlex number..

double real;

double img;

};

complex make_complex(double a,double b)//function to return complex number with two arguments of type double..

{

   complex n1;

   n1.real=a;

   n1.img=b;

   return n1;//returning complex number..

}

int main() {

   complex n;

   double a,b;

   cout<<"Enter real and Imaginary respectively"<<endl;

   cin>>a>>b;//taking input of real and imaginary parts..

   n=make_complex(a,b);//calling function..

   cout<<"Comlex number is : "<<n.real<<" + i"<<n.img;//printing the output..

return 0;

}

output:-

Enter real and Imaginary respectively

5.4 8.9

Comlex number is : 5.4 + i8.9

Explanation:

First I have created a structure for complex number.Then created a function to make complex number according to the question which returns a complex number.

You might be interested in
It is possible to change the shape of a text box.
maw [93]
Yes drag the arrow over the edge and drag it to the size you want
5 0
3 years ago
Read the excerpt from The Code Book. Other attacks include the use of viruses and Trojan horses. Eve might design a virus that i
antiseptic1488 [7]

Answer:

Tell about an experience with a computer virus.

Explanation:

Simon Singh's "The Code Book," tells the history of how cryptography came into being and the secret messaging world of encryption. Through the detailed narration and diving into the history of encryption, the author traces the evolution of such a process and reveals how it has had a huge impact on the world's policies.

In the given excerpt, Singh gives an example of how viruses are planted and used to spy/ get access to other people's computers. But while it is possible to get the main point of the example, <u>it would have been better if the writer includes experience with a computer virus</u> so that readers will find it easier to connect with the given example. This will enable them to better understand the working of viruses and their effects.

Thus, the correct answer is the first option.

3 0
3 years ago
How does the team know what to work upon during the iteration
Brilliant_brown [7]

Answer:

Based on the discussions during iteration planning, team members agree on what each would work on.

Explanation:

Iteration can be defined as the way in which a process is been repeated in order to generate a possibly outcomes and this occur in a situation where the sequence will approach some end point in which each repetition of the process will be a single iteration while the outcome of each iteration will then be the starting point of the next iteration.

Therefore the team know what to work upon during the iteration Base on the discussions during iteration planning in which the team members agree on what each of them would work on.

During the iteration planning, the team collectively make a decision on how much of the backlog actually they will commit to the iteration in which the committed backlog then is taken to the delivery during the next iteration which is why the goals or objectives of the iteration get determined on the basis of the work committed.

7 0
3 years ago
What are some ways to find out what skills you need to develop at work? Check all of the boxes that apply.
Anarel [89]

Answer:

Attend traings

Explanation:

Because if you do you can learn diffent waay to do it and choose your way that you like.

ANd do not obseve poeple who has it easy  

7 0
3 years ago
Read 2 more answers
What is the purpose of a format painter in Word?
Bond [772]

Answer:

The format painter lets you copy all of the formatting from one object and apply it to another one – think of it as copying and pasting for formatting. Select the text or graphic that has the formatting that you want to copy. Note: If you want to copy text formatting, select a portion of a paragraph

Explanation: pls mark my answer as brainlist

3 0
3 years ago
Read 2 more answers
Other questions:
  • Kim is creating a one-page presentation in Word about her parents’ home country, Vietnam. She has inserted images that are each
    7·2 answers
  • A ________ restricts the number of a certain type of product that can be imported into a country.
    5·1 answer
  • Does YouTube have the potential to change academia as we know it, or is that a bit of a stretch? Explain.
    9·2 answers
  • Choose two browsers and compare their security features.
    5·1 answer
  • Declare a char array named line of size 50, and write a statement that reads in the next line of console input into this array.
    6·1 answer
  • COMPUTER CODING
    5·1 answer
  • Who invented Leibnitz calculating machine ?
    12·1 answer
  • The graph shows households in the world with internet access from 2003 to 2019. A graph titled Percentage of Households with Int
    6·2 answers
  • 2) A simple operating system supports only a single directory but allows it to have arbitrarily many files with arbitrarily long
    7·1 answer
  • Is anyone a robIox moderator?
    13·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!