On 9/11/07, Robert Ryan <[EMAIL PROTECTED]> wrote:
> this is what I am working on
> #include <iostream>
>
> int add (int x, int y) {
> int z;
> z = x + y;
> return (z);
> }
>
> int sub (int x, int y) {
> int z;
> z = x - y;
> return (z);
> }
>
> int multi (int x, int y) {
> int z;
> z = x * y;
> return (z);
> }
>
> int div (int x, int y) {
> int z;
> z = x / y;
> return (z);
> }
>
> main ()
> {
> int i, j, k1, k2, k3, k4;
> i = 10;
> j = 20;
> k1 = + (i, j);
> k2 = - (i, j);
> k3 = * (i, j);
> k4 = / (i, j);
> cout("The result of k1, k2, k3 ,k4 is: \n", k1, k2, k3, k4);
> }
Why? It's all superfluous code (and won't work anyway, since you can't
overload operators the way you are trying).
-- Brett
------------------------------------------------------------
"In the rhythm of music a secret is hidden;
If I were to divulge it, it would overturn the world."
-- Jelaleddin Rumi