Wednesday, September 29, 2010

(OOPS) ADDITION OF COMPLEX NUMBERS

EX.NO:                       ADDITION OF COMPLEX NUMBERS
DATE:                                  USING FRIEND FUNCTION

AIM:

              To write a c++ program to sum two complex numbers using friend function.

ALGORITHM:

            STEP1: Start the process.

            STEP2: A friend function called sum is defined.

            STEP3: The values are passed as arguments.

            STEP4: Sum is calculated for the two complex numbers and stored in a object.

            STEP5: Then the sum value is displayed.

            STEP6: Stop the process.