Em Andamento

Classes

2. **The Problem (an enhanced version of Chapter 11, Programming Problem 3, page 659):** design, implement, and test a Rational class that represents a rational number as a pair of integers instead of a single floating-point number.

3. **More Details:**

A rational number is a number that can be expressed as a fraction whose numerator and denominator are integers. Examples of rational numbers are 0.75 (which is 3/4) and 1.125 (which is 9/8). The value p is not a rational number; it cannot be expressed as the ratio of two integers.

1. The *Rational* objects must be stored in their reduced form. In other words, the rational number 12/16 should be stored as 3/4. A private member function Reduce should be provided to reduce the *Rational* object.

2. The *Rational* class should have two class constructors. The first one lets the client specify an initial numerator and denominator. The other??"the default constructor??"creates the *Rational* number 0, represented as a numerator of 0 and a denominator of 1.

3. The *Rational* class should have arithmetic operations that add, subtract, multiply, and divide two *Rational* objects. These should be implemented as value-returning functions, each returning a *Rational* object.

4. The *Rational* class should have a Boolean operation that compares two *Rational* objects for equality.

5. The *Rational* class should have an input operation that reads a rational number from a designated input stream in the form numerator/denominator.

6. The *Rational* class should have an output operation that writes a rational number out to a designated output stream in the form numerator/denominator

## Deliverables

1) Complete and fully-functional working program(s) in executable form as well as complete source code of all work done.

2) Installation package that will install the software (in ready-to-run condition) on the platform(s) specified in this bid request.

3) Exclusive and complete copyrights to all work purchased. (No GPL, 3rd party components, etc. unless all copyright ramifications are explained AND AGREED TO by the buyer on the site).

## Platform

I use Microsoft Visual Studio C++ to do all my work. The source file has to be in .cpp format.

Habilidades: Programação C, Engenharia, MySQL, PHP, Arquitetura de software, Teste de Software

Ver mais: stream programming, programming classes, pair programming, integers form 1, floating point integers, c programming classes, c programming boolean, cpp programming, classes programming, boolean programming, cpp programming examples, rational class, php file operation, member function php, visual studio implement, class rational, rational numbers reduced form, classes, complete class rational numbers, rational number class, visual studio input form, code cpp, input form visual studio, form floating, program fraction reduced

Acerca do Empregador:
( 1 comentário ) United States

ID do Projeto: #3006643

Premiar a:

jonminter

See private message.

$7 USD em 18 dias
(33 Avaliações)
5.0

38 freelancers estão ofertando em média $11 para este trabalho

mihaiscortaru

See private message.

$16.15 USD in 18 dias
(160 Comentários)
6.0
bogdanstan

See private message.

$6.8 USD in 18 dias
(195 Comentários)
5.7
zeegaal

See private message.

$8.5 USD in 18 dias
(59 Comentários)
5.1
senzaciosnegyes

See private message.

$15.3 USD in 18 dias
(104 Comentários)
4.9
lmxvw

See private message.

$7.65 USD in 18 dias
(126 Comentários)
4.7
RandomTech

See private message.

$17 USD in 18 dias
(54 Comentários)
4.6
alexpyrkov

See private message.

$17 USD in 18 dias
(16 Comentários)
4.5
codeCrafter10

See private message.

$8.5 USD in 18 dias
(20 Comentários)
4.4
hajjs

See private message.

$12.75 USD in 18 dias
(17 Comentários)
4.3
bladvw

See private message.

$17 USD in 18 dias
(24 Comentários)
4.6
vw945703vw

See private message.

$3.4 USD in 18 dias
(22 Comentários)
4.2
shabbirbhimani

See private message.

$6.8 USD in 18 dias
(33 Comentários)
4.2
katchei

See private message.

$17 USD in 18 dias
(10 Comentários)
3.9
shashikhanvw

See private message.

$13.6 USD in 18 dias
(15 Comentários)
3.8
gworroll

See private message.

$12.75 USD in 18 dias
(42 Comentários)
3.7
hmichopoulos

See private message.

$17 USD in 18 dias
(27 Comentários)
3.7
vladimirlagutin

See private message.

$12.75 USD in 18 dias
(20 Comentários)
3.3
homeworktutor

See private message.

$12.75 USD in 18 dias
(12 Comentários)
2.4
claudiuvw

See private message.

$17 USD in 18 dias
(1 Comentário)
2.3
akindosolutions

See private message.

$17 USD in 18 dias
(4 Comentários)
2.3