I am trying to compare first byte of heading. What am I doing incorrect? My compiler give me error can't compare
In my process I am open a file then read line, from a line take first 4 bit and then compare.
int lineCount=0;
do
{inFile.getline(inBuffer,'~');//sizeof(inBuffer));
char heading[4];
if ((strcmp(heading[0], "S"
)==0)
{cout<<heading[0];}
lineCount++;
}while(!inFile.eof());
In my process I am open a file then read line, from a line take first 4 bit and then compare.
int lineCount=0;
do
{inFile.getline(inBuffer,'~');//sizeof(inBuffer));
char heading[4];
if ((strcmp(heading[0], "S"
{cout<<heading[0];}
lineCount++;
}while(!inFile.eof());