0

Hi everyone!.How to fix this error C2504?

(File mo.h) class mo { public: mo() { cout<<"constructor"<<endl; } ~mo() { cout<<"destructor"<<endl; } }; (File d.h) class d: public mo{ public: }; Int main() { } (It does not work with files)

9th Jan 2021, 4:43 PM
Buneodbek
Buneodbek - avatar
3 ответов
+ 2
The only errors I can see in your code are 1) nothing in main() 2) constructor and destructor of class mo are private ( edit : it have been fixed now ) Here is the fix👇 https://code.sololearn.com/c5FZPzKWlry3/?ref=app
9th Jan 2021, 4:51 PM
Arsenic
Arsenic - avatar
0
Ohh sorry
9th Jan 2021, 4:52 PM
Buneodbek
Buneodbek - avatar
0
In my computer was different ill fix
9th Jan 2021, 4:53 PM
Buneodbek
Buneodbek - avatar