How can i know if the first character is start with "/" or not ??Code:char *cdx[2]; cdx[1]="/home/dir";
if first char == "/" then
return 0;
else
return 1;
How can i know if the first character is start with "/" or not ??Code:char *cdx[2]; cdx[1]="/home/dir";
if first char == "/" then
return 0;
else
return 1;
Basically in a char array of characters it would work like this
but the way your code looks.. I think you could do thisCode:char text[5] = "Hello"; if(text[0] == 'H') return 0; else return 1;
if(cdx[1][0] == '/')
if im way of base, post your code so there will be no doubt as to what your trying to do.
How about isalnum?
Code:if( isalnum( text[0] ) printf("The first character is either a letter or a number.\n");
Hope is the first step on the road to disappointment.