String Comparison Function - strcmp()

preview_player
Показать описание
C Programming: String Comparison Function - strcmp() in C Language.
Topics discussed:
1) The prototype of strcmp() function.
2) Functionalities of strcmp() function.
3) Important points of the ASCII character set.
3) Example uses of strcmp() function.

Music:
Axol x Alex Skrindo - You [NCS Release]

#CProgrammingByNeso #CProgramming #Strings #strcmp #StringsInC
Рекомендации по теме
Комментарии
Автор

You're explanation is really Everyone can clearly understand...

arularasij
Автор

I would like to mention that what actually is get compared, are the ASCII codes for each character, not the characters themselves.

accessdenied
Автор

you know what.... TYSM bro, you have no idea how much you have helped... you saved a lot of my time... you're a lifesaver!

muneebtahir
Автор

Why is the output of this code greater or equal to s2
int main()
{
char *s1 = "xyz";
char *s2 = "cdeabzxydsf";
if(strcmp(s1, s2)<0)
printf("s1 is less then s2");
else
printf("s1 is either greater or equal to s2");
return 0;
}

rashmitbhanderi
Автор

About 12 years ago, I defined my own version of strcmp(), with a third - a bool - parameter, "CaseSensitive." I wish that it was written to do it that way, with a "true" default argument for that third parameter. But, my own version can't use a default argument, because it would create ambiguity, unless I changed the name of my version of the function.

cedwardmassey
Автор

Sir can you do lecture on computer science networking. Thank you

aritrasarkar
Автор

Sir please complete C programming as soon as possible.

SagarKumar-nhno
Автор

your teaching is fantastic and understandable.

vijaykounsalye
Автор

If I had like 100 strings in a .txt, and 100 more strings in other .txt, how can I make a program to read this two .txt and it give me what strings is different?

cond
Автор

What if str1 is longer than s2, but str1 begins with B and str2 begins with A

block
Автор

Not informative. u should run it in the Code blocks for better understanding

fahimahmed