This class stores the data as a string, but the operator overloads make it act like an integer. Problem is, I'm not quite sure how to go about doing this with the remaining operators. They're listed at the bottom of the post.

I want the remaining overloads (see the first post) to do what it would normally do with an integer or a string, depending on what data type it normally is used with. I want %= to do what it does for integers, that part is easy, but I need % in order to do that... 5%2=1

Also, I need ++ and --:

ooint c = 5;
c++; //add one to 5
c--; // subtract one from 5

[EDIT]%= Remainder assignment
% Modulus operator

I figured out those... those ones were obvious[/EDIT]

12-06-2002

Trauts

Also, with +, -, *, /, and % operators, I can't add a character like this:

ooint a = 0;
a = 1 + '3';

because I can't declare it in the class without it having a member of type ooint.

h:\ooint.h(98) : error C2803: 'operator +' must have at least one formal parameter of class type