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
WARRIOR [948]
3 years ago
14

Define a structure Triangle that contains three Point members. Write a function that computes the perimeter of a Triangle . Writ

e a program that reads the coordinates of the points, calls your function, and displays the result
Computers and Technology
1 answer:
qwelly [4]3 years ago
7 0

Answer:

The program in C++ is as follows:

#include <iostream>    

using namespace std;

int perimeter(int side1, int side2, int side3){

return side1+side2+side3;

}

struct Triangle  {

int side1;  int side2;   int side3;

};

int main(void) {

int side1, side2, side3;

cout<<"Sides of the triangle: ";

cin>>side1>>side2>>side3;

struct Triangle T;

T.side1 = side1;

T.side2 = side2;

T.side3 = side3;  

cout << "Perimeter: " << perimeter(T.side1,T.side2,T.side3) << endl;

return 0;

}

Explanation:

See attachment for complete code where comments are as explanation

Download cpp
You might be interested in
Please Complete in Java a. Create a class named Book that has 5 fields variables: a stock number, author, title, price, and numb
Gala2k [10]

Answer:

Explanation:

The following code is written in Java. I created both versions of the program that was described in the question. The outputs can be seen in the attached images below. Both versions are attached as txt files below as well.

Download txt
<span class="sg-text sg-text--link sg-text--bold sg-text--link-disabled sg-text--blue-dark"> txt </span>
<span class="sg-text sg-text--link sg-text--bold sg-text--link-disabled sg-text--blue-dark"> txt </span>
13e8818abb53c8bc7547a966a10a101d.jpg
8623bf9304771a3e1c8581a41a9c11f6.jpg
8 0
3 years ago
Sergio knows that to meet the project requirements, it is essential to have
zhenek [66]

Answer:

I need a better explanation??

4 0
3 years ago
Enter just the letter of the correct answer
Viefleur [7K]

Answer:

C. WDS

Explanation:

DND is for rolling dice and arguing about alignments

WiFi Analyzer just monitors your WiFi's stats and health

--> WDS lets you wirelessly connect two routers for larger range

DHCP is for IP address distribution.

3 0
3 years ago
You are considering implementing a backup scheme for a server. After researching options, you decide on a method that does not r
Alecsey [184]

Answer:

C. A cold site is a leased facility that contains only electrical and communications wiring, air conditioning, plumbing, and raised flooring. No communications equipment, networking hardware, or computers are installed at a cold site until it is necessary to bring the site to full operation.

Explanation:

3 0
3 years ago
Critical Thinking Questions
Hoochie [10]

Answer:

One example of syntax in Logo is “[”. Two examples of Java are “;” and “{“or “}”. If you don’t use these parts of syntax then you could get a Syntax error, this will make you have to stop the code and debug.

Explanation:

6 0
2 years ago
Read 2 more answers
Other questions:
  • Using a pin or password in addition to tpm is an example of what type of authentication?
    13·1 answer
  • When Amy turns on her computer, she notices a burning smell. Smoke comes out of the case, and Amy immediately turns off her comp
    7·1 answer
  • Binary code what does this mean I was sick so I don't under stand
    7·2 answers
  • What are the four primary factors described in the text that set the state for Web 2.0 or the social Web that we enjoy today??
    12·1 answer
  • Given an input array of strings (characters) s, pick out the second column of data and convert it into a column vector of data.
    14·1 answer
  • Which of the following is most likely to be considered plagiarism? a. Intentionally reporting the results of inaccurate statisti
    11·1 answer
  • 1. Write a class for time objects that store three integer values for hour, minute, and second. Also, write a program to test th
    13·1 answer
  • My brainly isnt working it isnt showing and answers wats going on? wat do i do
    14·2 answers
  • Please help me on this coding problem :)
    6·1 answer
  • What type of software is needed access the internet
    14·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!