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
vladimir1956 [14]
3 years ago
13

A point in the x-y plane is represented by its x-coordinate and y-coordinate. Design the class Point that can store and process

a point in the x-y plane. You should then perform operations on a point, such as showing the point, setting the coordinates of the point, printing the coordinates of the point, returning the x-coordinate, and returning the y-coordinate. Also, write a test program to test various operations on a point.
Engineering
1 answer:
Black_prince [1.1K]3 years ago
5 0

Answer:

#include <iostream>

#include <iomanip>

using namespace std;

class pointType

{

public:

pointType()

{

x=0;

y=0;

}

pointType::pointType(double x,double y)

{

this->x = x;

this->y = y;

}          

void pointType::setPoint(double x,double y)

{

this->x=x;

this->y=y;

}

void pointType::print()

{

cout<<"("<<x<<","<<y<<")\n";

}

double pointType::getX()

{return x;

}

double pointType::getY()

{return y;

}

private:

   double x,y;

};

int main()

{

pointType p2;

double x,y;

cout<<"Enter an x Coordinate for point ";

cin>>x;

cout<<"Enter an y Coordinate for point ";

cin>>y;

p2.setPoint(x,y);

p2.print();

system("pause");    

return 0;

}

You might be interested in
I WILL GIVE BRAINLIEST IF ANSWER FAST What is the measurement on this Dial Caliper?
garik1379 [7]

Answer:

b i think i dont see any dial caliper

Explanation:

8 0
3 years ago
Look at the home page of the Internet Society (www.internetsociety.org) and read about one of the designers of the original ARPA
krek1111 [17]

Answer:

<u>ARPANET is the direct precedent for the Internet, a network that became operational in October 1969 after several years of planning. </u>

Its promoter was DARPA (Defense Advanced Research Projects Agency), a US government agency, dependent on the Department of Defense of that country, which still exists.

Originally, it connected research centers and academic centers to facilitate the exchange of information between them in order to promote research. Yes, being an undertaking of the Department of Defense, it is understood that weapons research also entered into this exchange of information.

It is also explained, without being without foundation, that the design of ARPANET was carried out thinking that it could withstand a nuclear attack by the USSR and, hence, probably the great resistance that the network of networks has shown in the face of major disasters and attacks.

It was the first network in which a packet communication protocol was put into use that did not require central computers, but rather was - as the current Internet is - totally decentralized.

Explanation:

<em><u> Below I present as a summary some of the most relevant aspects exposed on the requested website about the origin and authors of ARPANET:</u></em>

<em><u></u></em>

1. Licklider from MIT in August 1962 thinking about the concept of a "Galactic Network". He envisioned a set of globally interconnected computers through which everyone could quickly access data and programs from anywhere. In spirit, the concept was very much like today's Internet. He became the first head of the computer research program at DARPA, and from October 1962. While at DARPA he convinced his successors at DARPA, Ivan Sutherland, Bob Taylor and MIT researcher Lawrence G. Roberts, of the importance of this network concept.

2.Leonard Kleinrock of MIT published the first article on packet-switching theory in July 1961 and the first book on the subject in 1964. Kleinrock convinced Roberts of the theoretical feasibility of communications using packets rather than circuits, That was an important step on the road to computer networking. The other key step was to get the computers to talk together. To explore this, in 1965, working with Thomas Merrill, Roberts connected the TX-2 computer in Mass. To the Q-32 in California with a low-speed phone line creating the first wide-area (albeit small) computer network built . The result of this experiment was the understanding that timeshare computers could work well together, running programs and retrieving data as needed on the remote machine, but that the circuitry switching system of the phone was totally unsuitable for the job. Kleinrock's conviction of the need to change packages was confirmed.

3.In late 1966 Roberts went to DARPA to develop the concept of a computer network and quickly developed his plan for "ARPANET", and published it in 1967. At the conference where he presented the document, there was also a document on a concept of UK packet network by Donald Davies and Roger Scantlebury of NPL. Scantlebury told Roberts about NPL's work, as well as that of Paul Baran and others at RAND. The RAND group had written a document on packet switched networks for secure voice in the military in 1964. It happened that work at MIT (1961-1967), in RAND (1962-1965) and in NPL (1964-1967) all they proceeded in parallel without any of the investigators knowing about the other work. The word "packet" was adopted from the work in NPL and the proposed line speed to be used in the ARPANET design was updated from 2.4 kbps to 50 kbps.

6 0
3 years ago
The voltage and current at the terminals of the circuit element in Fig. 1.5 are zero fort &lt; 0. Fort 2 0 they areV =75 ~75e-10
masya89 [10]

Answer:

maximum value of the power delivered to the circuit =3.75W

energy delivered to the element = 3750e^{ -IOOOt} - 7000e ^{-2OOOt} -3750

Explanation:

V =75 - 75e-1000t V

l = 50e -IOOOt mA

power = IV = 50 * 10^-3 e -IOOOt * (75 - 75e-1000t)

=50 * 10^-3 e -IOOOt *75 (1 - e-1000t)

=

maximum value of the power delivered to the circuit =3.75W

the total energy delivered to the element = \int\limits^t_0  {3.75(e^{ -IOOOt} - e ^{-2OOOt} )} , dx \\\\

3750e^{ -IOOOt} - 7000e ^{-2OOOt} -3750

5 0
3 years ago
A function is different from a procedure because a functiondoes not contain a set of instructions.can have only a limited number
777dan777 [17]

Answer: A function returns a value and a procedure just executes commands.

Explanation:

6 0
2 years ago
Read 2 more answers
A load of 1 kg is applied to the tip of a cantilever beam with a width b = 2.5 cm, a thickness h = 1 mm, length L = 20 cm, modul
garik1379 [7]

Answer:

20 g/cm3 divide by 6 is 20

4 0
3 years ago
Read 2 more answers
Other questions:
  • Sed is a multipurpose tool that combines the work of several filters. sed performs noninteractive operations on a data stream. s
    12·1 answer
  • Kirchoff's Law states that, by the time current has returned to its source, all
    13·2 answers
  • Nitrogen can be liquefied using a Joule-Thomson expansioni process. This is done by rapidlyl and adiabatically expandign cold ni
    15·1 answer
  • A heat pump receives heat from a lake that has an average wintertime temperature of 6o C and supplies heat into a house having a
    12·1 answer
  • Nitrogen enters a steady-flow heat exchanger at 150 kPa, 10°C, and 100 m/s, and it receives heat as it flows through it. Nitroge
    15·1 answer
  • PLEASE HELP!!! <br><br>I've included attachments. Can someone just check my answers pls??
    9·1 answer
  • For each of the resistors shown below, use Ohm's law to calculate the unknown quantity, Be sure to put your answer in proper eng
    8·1 answer
  • Proper handling of blueprints includes which of the following
    5·1 answer
  • Work to be performed can come from the work package level of the work breakdown structure as well as other sources. Which of the
    11·1 answer
  • For installations where the nonlinear load is huge, most consulting engineers will specify ____-rated transformers.
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!