Logo

Programming-Idioms

History of Idiom 39 > diff from v36 to v37

Edit summary for version 37 by suresh:
New C implementation by user [suresh]

Version 36

2017-07-07, 18:37:07

Version 37

2017-07-17, 06:20:57

Idiom #39 Check if string contains a word

Set boolean ok to true if string word is contained in string s as a substring, or to false otherwise.

Idiom #39 Check if string contains a word

Set boolean ok to true if string word is contained in string s as a substring, or to false otherwise.

Imports
#include<stdio.h>
#include<conio.h>
#include<string.h>
 
 
Code
int main()

{
char str[30]=”www.cprogrammingexpert.com”;
clrscr();
printf(“\n str = %s” , str);
printf(“\n strlen(str)= %d \n”,strlen(str));
getch();
return 0;
}
Doc URL
http://cprogrammingexpert.com/c-tutorial/c-string/c-strlen/
Origin
http://cprogrammingexpert.com/c-tutorial/c-string/c-strlen/