>>6
i don't think so, this problem is a challenge and that feels like cheating, someone said something about class friendship but i couldn't use that at all
Name:
Anonymous2010-11-08 23:34
btw this shit was int my first Algorithms and Data Structures I exam
>>14
>I can't change the integers to public
Oh MB.
new updated version
class X
{
private:
int x;
public:
X(int i)
{
x=i;
}
int getX()
{
return x;
}
};
class Y
{
private:
int y;
public:
Y(int i)
{
y=i;
}
int getY(){return x;}
};
int operator +(X &p1, Y &p2){return p1.getX()+p2.getY();};
Name:
Anonymous2010-11-09 0:41
>>18
i must add stuff ONLY inside X and Y, i cant change change "int operator +(X &p1, Y &p2){return p1.x+p2.y;}; "
Name:
Anonymous2010-11-09 0:47
OP HERE, okay i'll try to explain clearly all the rules for this :
First of all you cnn only add stuff inside the two classes, you can't remove nothing, you can't change nothing, okay?
/prog/ is nothing less than /b/... It simply sucks, and it sucked since the Internet was young. And you, bitches, still don't get it.
In the last week I've tried to post some useful questions, and check how good /prog/ is... The only thing that I've noticed is a lot of dumbfags posting SICP and FIOC . You are clueless dogshit, and there's nothing to do about it.
>>29
No, no. I followed a link to some archive, and tried sitting through a thread about ordering pizza. Needles to say, I failed.
/b/ is far worse, and I'm pretty sure I have bitch tits.