Write a fucntin defintion for the line class constructor

Assignment Help C/C++ Programming
Reference no: EM13937815

The following class uses composition to define a line object in terms of two point objects.

class line
{
public:
Point startingpoint();
point endingpoint();
float length();
line (int startX, int startY, int endX, int endY);

private:
point startPoint;
point endPoint:

};

1) write a fucntin defintion for the Line class constructor

2) for the line class implement the StartingPoint() and EndingPoint() member functions

3) for the line class implement the lenght() member function. the distance between two points (x1,y1) and (x2,y2) is sqrt ((x1,x2)2 + (x2,y2)2)

Reference no: EM13937815

Questions Cloud

Data presentation and analysis : Research topic Use of English. The end result should be a research report approximately 2,500- 3,000 words in length and structured like the report plan The distribution of maximum marks is as follows:
Produce a short technical report : This is a research assignment to produce a short technical report (apprpximately between 1000-2000 words plus diagrams and figures) with an appropriate referencing list and citations following APA styling.
Based on the limited information provided : Based on the limited information provided, give Cindy an estimate of the net effect of the coupon campaign on annual profit. (Ignore taxes.)
Electric air-furnace capable of temperatures : A material is required for the interior wall of electric air-furnace capable of temperatures up to 1275 K. Think out what attributes a material must have if it is to be made into windings and function properly in a furnace. List the function and t..
Write a fucntin defintion for the line class constructor : The following class uses composition to define a line object in terms of two point objects.
Determine the load from the floor beam : Determine the load from the floor beam, B, that is being supported at the middle of beam A. The floor that it supports has a weight of 0.4 kN/m2; an area 2.5 metres by 6 metres is being carried by the floor beam, half of which is being transferred..
Function definitions of the pixel class constructor : Write client code to print out the current X and coordiantes and the status of the first pixel
Describe the entity underlying business model : Select one of the following entities; Google, Yahoo, DropBox or Amazon. Briefly, describe the entity's underlying business model. Possible approaches for the analysis of the entity's underlying business model include Balanced Scorecard style appro..
Fundamental of structures : a) Find the tensions of the cable CG and FG. b) Find the reactions at A and B. c) By the method of joints to calculate the forces of member AC and CD. d) By the method of sections to calculate the force of member DB.

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Create program that uses functions and reference parameters

Create program that uses functions and reference parameters, and asks user for the outside temperature.

  Write a program using vectors and iterators

Write a program using vectors and iterators that allows a user to maintain a personal list of DVD titles

  Write the code required to analyse and display the data

Calculate and store the average for each row and column. Determine and store the values for the Average Map.

  Write a webservices application

Write a webservices application that does a simple four function calculator

  Iimplement a client-server of the game

Iimplement a client-server version of the rock-paper-scissors-lizard-Spock game.

  Model-view-controller

Explain Model-View-Controller paradigm

  Design a nested program

How many levels of nesting are there in this design?

  Convert celsius temperatures to fahrenheit temperatures

Write a C++ program that converts Celsius Temperatures to Fahrenheit Temperatures.

  Evaluate and output the value in the given base

Write C program that will input two values from the user that are a Value and a Base with which you will evaluate and output the Value in the given Base.

  Design a base class shape with virtual functions

Design a base class shape with virtual functions

  Implementation of classes

Implementation of classes Chart and BarChart. Class barChart chould display a simple textual representation of the data

  Technical paper: memory management

Technical Paper: Memory Management, The intent of this paper is to provide you with an in depth knowledge of how memory is used in executing, your programs and its critical support for applications.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd