You may see this error for writing wrong expression to initialize an array. See the code below:
int data={42,15,27,20,19};
If you compile this, you will see the following error message:
illegal initializer for intint data={42,15,27,20,19}; ^
Here the array is not declared properly as we have not put [ ] for declaring the array. The correct code is:
int data[ ]={42,15,27,20,19};
or
int[ ]...
Read More