Обсуждения
Programmers out there
1 голос
2 ответовcan anyone plz explain me this program step by step?#include <iostream>
using namespace std;
class MyClass {
public:
int var;
MyClass() { }
MyClass(int a)
: var(a) { }
MyClass operator+(MyClass &obj) {
MyClass res;
res.var= this->var+obj.var;
return res;
}
};
int main() {
MyClass obj1(12), obj2(55);
MyClass res = obj1+obj2;
cout << res.var;
}I am not getting the part inside operator+
0 голосов
8 ответовReal life programming
2 голосов
2 ответовWhich IDE is good? Turbo or Geany?
0 голосов
4 ответовWhat exactly is Java Script?
0 голосов
2 ответовhow to make website
-1 голос
3 ответовАктуальное сегодня
Pig Latin
0 Votes
Someone can help me
0 Votes
Square Roots
0 Votes
What's wrong with this?
2 Votes
I’m new someone can help me
0 Votes
What's doctype htMl
2 Votes
HTML community, HELP!!
0 Votes