Question: to search 's' linearly in a list of strings

as an alternative to strcmp function,can we use 2 nested for loops and put the conditions as:
if(a[i][j]==‘s’)
{
cout<<“s found”;
}

@himanshuep32 Yes you can do that for characters.

but if instead of ‘s’, I want to compare ‘sunday’,can i use the same thing?

no this cannot be done.