how to find string length wihtout using c function?

Answer Posted / ankitecian

int StrLen(const char *_input)
{
int _len = 0;
while( *(_input + _len) != NULL)
{
_len++;
}
return _len;
}

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the primitive data types in c?

579


Which of the following operators is incorrect and why? ( >=, <=, <>, ==)

672


How can you return multiple values from a function?

638


What's the right way to use errno?

628


What is #ifdef ? What is its application?

651






Can an array be an Ivalue?

668


Read the following data in two different files File A: aaaaaaaadddddddd bbbbbbbbeeeeeeee ccccccccffffffff File B: 11111111 22222222 33333333 By using the above files print the following output or write it in the Other file as follows aaaaaaaa11111111dddddddd bbbbbbbb22222222eeeeeeee cccccccc33333333ffffffffffff

2244


What is the difference between fread buffer() and fwrite buffer()?

676


Differentiate between the = symbol and == symbol?

721


How old is c programming language?

582


Why is main function so important?

619


What language is c written?

580


Where are the auto variables stored?

628


What is wrong in this statement?

608


What is use of #include in c?

603