Custom "Very Long Int" Division Issue

Posted by befall on Stack Overflow See other posts from Stack Overflow or by befall
Published on 2010-03-26T17:06:57Z Indexed on 2010/03/26 18:03 UTC
Read the original article Hit count: 256

Filed under:
|
|

Hey everyone,

So, for a very silly project in C++, we are making our own long integer class, called VLI (Very Long Int). The way it works (they backboned it, blame them for stupidity) is this:

  1. User inputs up to 50 digits, which are input as string.
  2. String is stored in pre-made Sequence class, which stores the string in an array, in reverse order.

That means, when "1234" is input, it gets stored as [4|3|2|1].

So, my question is this: How can I go about doing division using only these arrays of chars?

If the input answer is over 32 digits, I can't use ints to check for stuff, and they basically saying using long ints here is cheating.

Any input is welcome, and I can give more clarification if need be, thanks everyone.

© Stack Overflow or respective owner

Related posts about c++

Related posts about class