[Solved] CSCI204/MCS9204/CSCI804 Object and Generic Programming in C++ Laboratory Exercise 3 (Week 4)

30 $

File Name: CSCI204/MCS9204/CSCI804_Object_and_Generic_Programming_in_C++_Laboratory_Exercise_3_(Week_4).zip
File Size: 866.64 KB

SKU: [Solved] CSCI204/MCS9204/CSCI804 Object and Generic Programming in C++ Laboratory Exercise 3 (Week 4) Category: Tag:

Or Upload Your Assignment Here:


5/5 – (1 vote)

Task: Constructors, destructor (1.0)Define a class BigInteger in a file BigInteger.h that can be used to store a large positive integer. The class contains two data members: a pointer of short integer and the size of the dynamic short integer array. Define the following member functions:• The default constructor;• An initialization constructor initializes a BigInteger instance with a long long integer;• An initialization constructor initializes a BigInteger instance with a char array, inwhich all elements are decimal digits.• The copy constructor makes a deep copy from a BigInteger instance.• The destructor;• Add function adds the current instance with another BigInteger instance and returns the result of the addition.• Print function print out the current BigInteger value to an output stream.Implement the member functions defined above in a file BigInteger.cpp.Write the driver program include main function in a file testMain.cpp to declare instances of BigInteger, test all the member functions defined above. The values are up to you (Do not read input data from the keyboard or a file).

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[Solved] CSCI204/MCS9204/CSCI804 Object and Generic Programming in C++ Laboratory Exercise 3 (Week 4)
30 $