Hello,
I am trying to use a class with C++ but when i try to compile it it only sais parse error:
10 main.cpp
parse error before `{'
Here is the code:
I don't even know for sure that the ; sign after the class is correct, in some code samples i have seen it was there, in others not.
Can anybody tell me what i am doing wrong?
I use Dev-C++ to compile this code
Thanks
I am trying to use a class with C++ but when i try to compile it it only sais parse error:
10 main.cpp
parse error before `{'
Here is the code:
Code:
#include <stdio.h>
#include <iostream.h>
using namespace std;
int main()
{
return 0;
}
class ops:{
public:
char osname;
};
I don't even know for sure that the ; sign after the class is correct, in some code samples i have seen it was there, in others not.
Can anybody tell me what i am doing wrong?
I use Dev-C++ to compile this code
Thanks
Comment