Find Jobs
Hire Freelancers

Implementing a class dealing with imaginary numbers

$5-10 USD

Completed
Posted about 21 years ago

$5-10 USD

Paid on delivery
Create a program implementing a class Complex having floating point data members for the real and the imaginary part of a complex number. The class must have the following member functions: • a default constructor that sets both the real and imaginary parts to zero • an initialization constructor • a function for setting the value of a Complex object • a function for extracting a Complex value from an input stream o numbers are entered in a+bi or a-bi format • a function to insert a Complex value in an input stream (in a+bi or a-bi format) • functions to perform addition, subtractions and multiplication of Complex objects In addition to the member functions above, overload the +, -, *, >> and << operators to work appropriately for Complex objects. Place the entire implementation of the class Complex in a file named Complex.cpp. This file will then be included by the program that tests it. You have to provide a function main() that invokes each element of the class several times in order to illustrate that they work properly. This means: • at least one Complex object is declared without being initialized • at least one Complex object is initialized at declaration • at least one Complex object has its value set • at least one Complex object is input using the extraction operator • at least one Complex object is output using the insertion operator • numbers with both positive and negative real and imaginary parts will be used Each function should have a short comment describing its action. ## Deliverables 1) Complete and fully-functional working program(s) in executable form as well as complete source code of all work done. ## Platform C++
Project ID: 2910004

About the project

15 proposals
Remote project
Active 21 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
Awarded to:
User Avatar
See private message.
$5 USD in 14 days
4.2 (110 reviews)
4.4
4.4
15 freelancers are bidding on average $7 USD for this job
User Avatar
See private message.
$8.50 USD in 14 days
4.9 (325 reviews)
7.6
7.6
User Avatar
See private message.
$8.50 USD in 14 days
4.5 (141 reviews)
6.0
6.0
User Avatar
See private message.
$6.80 USD in 14 days
4.8 (34 reviews)
4.4
4.4
User Avatar
See private message.
$8.50 USD in 14 days
5.0 (18 reviews)
4.2
4.2
User Avatar
See private message.
$8.50 USD in 14 days
5.0 (17 reviews)
3.8
3.8
User Avatar
See private message.
$8.50 USD in 14 days
4.9 (24 reviews)
3.5
3.5
User Avatar
See private message.
$7.65 USD in 14 days
4.7 (17 reviews)
3.0
3.0
User Avatar
See private message.
$3.40 USD in 14 days
5.0 (5 reviews)
2.7
2.7
User Avatar
See private message.
$5.10 USD in 14 days
3.9 (24 reviews)
2.8
2.8
User Avatar
See private message.
$8.50 USD in 14 days
5.0 (8 reviews)
2.3
2.3
User Avatar
See private message.
$6.80 USD in 14 days
5.0 (11 reviews)
1.6
1.6
User Avatar
See private message.
$5.10 USD in 14 days
5.0 (3 reviews)
0.7
0.7
User Avatar
See private message.
$3.40 USD in 14 days
0.0 (0 reviews)
0.0
0.0
User Avatar
See private message.
$8.50 USD in 14 days
0.0 (0 reviews)
0.0
0.0

About the client

Flag of UNITED STATES
United States
5.0
2
Member since Nov 26, 2002

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.