Thread: 123456789*123456789

  1. #1
    Registered User Robert_Ingleby's Avatar
    Join Date
    Oct 2001


    I have been set the task of multiplying 123456789 by 123456789 using borland 3.1.

    Its obvious to anyone what the problems going to be!!!

    But...... How do I get round it?

    In other words, how do I do this calculation using C or C++ in a DOS compiler.

    It can be done, but how or where do I start?

    To make matters worse, I have to prove my calculation by dividing the answer by 123456789 and ending up with 123456789 to prove my program actually works!!!!


  2. #2
    Registered User
    Join Date
    Dec 2001
    double unsigned float x;


  3. #3
    ATH0 quzah's Avatar
    Join Date
    Oct 2001
    floats / doubles cannot be unsigned.

    You'll likely have to break it digit by digit and store them in a linked list / array, write your own multiplicaiton / carry function (recursion would work incely) and do it that way.

    Hope is the first step on the road to disappointment.

Popular pages Recent additions subscribe to a feed
Website Security Test