What will be returned in the following C code?
Posted: Wed Jul 13, 2022 7:56 pm
size- t strlen(const char *s)
const char *sc;
for(sc = s; *sc!= ' \ O ' ; ++sc)
return(sc - s) ;
a) number of characters equal in sc
b) length of string s
c) doesn’t return any value
d) displays string s
const char *sc;
for(sc = s; *sc!= ' \ O ' ; ++sc)
return(sc - s) ;
a) number of characters equal in sc
b) length of string s
c) doesn’t return any value
d) displays string s