Sep 21, 2017 term paper 2

C++

This paper concentrates on the primary theme of C++ in which you have to explain and evaluate its intricate aspects in detail. In addition to this, this paper has been reviewed and purchased by most of the students hence; it has been rated 4.8 points on the scale of 5 points. Besides, the price of this paper starts from £ 40. For more details and full access to the paper, please refer to the site.

For this program you will declare a class for 3 dimensional solids and perform some arithmetic operations objects of that type.

Overall Procedure:

You will declare athree_d class as follows:

classthree_d

{

int *x, *y, *z;

public:

three_d() {};

three_d(inti,intj,intk)

{

x =newint;

*x =i;

y =newint;

*y =j;

z =newint;

*z =k;

};

int get_x ()

{return *x;};

int get_y ()

{return *y;};

int get_z ()

{return *z;};

// – as friend

friendthree_doperator- (three_d &op1,three_d op2);

// assignment as member

three_doperator=(three_d &op2);// op1 is implied

// prefix ++ as member

three_dthree_d::operator++();

// output stream as friend

friendostream &operator

};

You will also have an overloaded addition of two three_d objects implemented as a free function.

You must use an overloaded output stream operator to print results.

In main, you will declare twothree_dobjects,three_d_a andthree_d_b. Then you will exercise your code to produce the following output:

Coordinates three_d_a are:

1, 2, 3

Coordinates three_d_b are:

0, 2, 1

Coordinates of three_d_a after adding three_d_b are:

1, 4, 4

Coordinates three_d_a after subtracting three_d_b are:

1, 2, 3

Coordinates three_d_a after adding 1 to each member using a prefix ++ are:

2, 3, 4


0% Plagiarism Guaranteed & Custom Written, Tailored to your instructions


International House, 12 Constance Street, London, United Kingdom,
E16 2DQ

UK Registered Company # 11483120


100% Pass Guarantee

Order Now

STILL NOT CONVINCED?

We've produced some samples of what you can expect from our Academic Writing Service - these are created by our writers to show you the kind of high-quality work you'll receive. Take a look for yourself!

View Our Samples

corona virus stop
FLAT 25% OFF ON EVERY ORDER.Use "FLAT25" as your promo code during checkout