Hi,
I have situation in C++ where in I'll have to add around 20-25 conditions <compare a variable against a number> to an if statement.
Is there any limit on the number of expressions/conditions to be added to an if statement.
+++++++++++++++ +++++++++++++++ +++++++++++++++ +++++++++++
sample code.
+++++++++++++++ +++++++++++++++ +++++++++++++++ +++++++++++
x = 10;
if...
User Profile
Collapse
-
Prashanth Kumar B R started a topic Is there any limit on the number of conditions to be added in an if stmtin CIs there any limit on the number of conditions to be added in an if stmt
-
Error C2143 and C2059
Hello,
I have the below typedef statements in one of my header file.
//
// Type Definitions
//
typedef unsigned long DWORD;
typedef unsigned int UINT;
typedef unsigned short WORD;
typedef unsigned char BYTE;
typedef unsigned char UNCHAR;
typedef int BOOL;
typedef unsigned int UINT32;
typedef unsigned char UINT8;
typedef unsigned short... -
Initialization list
My companies C++ coding standard states that "Member initialization list should be used instead of assignment". I have a datamember that has to be initialized through a function call. Can I have function calls in initialization list. -
Is there any way by which i can access the Element of the derived class from *Ptr?... -
Accessing derived class data members
How can i access a public data member of a derived class with a pointer to the base class.
class Base
{
public:
Base(){};
virtual ~Base(){};
virtual bool decode(AOC_Stri ng element_text) ;
}
class Derived: pubilc Base
{
pubilc:
int ele;
bool decode(AOC_Stri ng element_text)
{
}
}
Base *Ptr = (Base *)new(Derived);...
No activity results to display
Show More
Leave a comment: