#include<iostream.h>
void main()
{
class x
{
public:
int func(int)
{
cout<<"cool";
return 1;
}
}
}
Answer / m.shanmuga sundaram,rjnsoftwar
An user defined data type should end with a semi colon
otherwise returns "error syntax error : missing ';'
before '}'"
#include<iostream.h>
void main()
{
class x
{
public:
int func(int)
{
cout<<"cool";
return 1;
}
} ; /*An user defined data type should end with a
semi colon*/
}
| Is This Answer Correct ? | 13 Yes | 7 No |
what is static function
What C++ libraries are you proficient with?
What is using namespace std in c++?
Explain the need for "Virtual Destructor"?
What is the standard template library (stl)?
Will c++ be replaced?
Where are setjmp and longjmp used in c++?
Define a constructor - what it is and how it might be called (2 methods)?
In a class only declaration of the function is there but defintion is not there then what is that function?
How do I open binary files?
What is an adjust field format flag?
Differentiate between a template class and class template?