String Comparison Function - strcmp()

Поділитися
Вставка
  • Опубліковано 22 гру 2024

КОМЕНТАРІ •

  • @accessdenied9393
    @accessdenied9393 3 роки тому +9

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

  • @arularasij3099
    @arularasij3099 4 роки тому +5

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

  • @muneebtahir
    @muneebtahir 2 роки тому +2

    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!

  • @gowthams4360
    @gowthams4360 3 місяці тому +1

    abc < abcd because at last ending of the string in abc we have null whose assci is 0 which is less than the equivalent assci value of d
    ..............vijay babu .............understood

  • @vijaykounsalye
    @vijaykounsalye 5 років тому +4

    your teaching is fantastic and understandable.

    • @laneshane9721
      @laneshane9721 3 роки тому

      sorry to be off topic but does someone know of a method to get back into an Instagram account..?
      I stupidly lost the password. I would love any help you can give me.

    • @holdencrew8449
      @holdencrew8449 3 роки тому

      @Lane Shane Instablaster :)

    • @laneshane9721
      @laneshane9721 3 роки тому

      @Holden Crew thanks for your reply. I found the site through google and I'm in the hacking process now.
      I see it takes quite some time so I will get back to you later with my results.

    • @laneshane9721
      @laneshane9721 3 роки тому

      @Holden Crew it worked and I actually got access to my account again. Im so happy:D
      Thanks so much, you really help me out !

    • @holdencrew8449
      @holdencrew8449 3 роки тому

      @Lane Shane Happy to help =)

  • @rashmitbhanderi596
    @rashmitbhanderi596 3 роки тому +5

    Why is the output of this code greater or equal to s2
    int main()
    {
    char *s1 = "xyz";
    char *s2 = "cdeabzxydsf";
    if(strcmp(s1,s2)

    • @pradhanan9413
      @pradhanan9413 3 роки тому +2

      S1 is greater than S2
      Because we should give priority to the ASCII table and then consider the length of the strings.
      Idk the reason but I executed this and checked

  • @cedwardmassey
    @cedwardmassey 2 роки тому

    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.

  • @kunalsoni7681
    @kunalsoni7681 5 років тому +2

    nice one presentation sir 😙❤😍😙

  • @aadarshvarma6313
    @aadarshvarma6313 4 роки тому +1

    Thank you so much 👍👍🙌🙌🙌🙌

  • @Gunstun0p
    @Gunstun0p 5 років тому +1

    Thanks for sharing this much

  • @RaphaelRafatpanah
    @RaphaelRafatpanah Рік тому

    Excellent explanation

  • @RahulKumar-no3rs
    @RahulKumar-no3rs 5 років тому +1

    U r the best

  • @SagarKumar-nh3no
    @SagarKumar-nh3no 5 років тому +1

    Sir please complete C programming as soon as possible.

  • @niranjanaprasad4293
    @niranjanaprasad4293 2 роки тому

    Thank you very much💜

  • @dafancy6345
    @dafancy6345 4 роки тому

    Thank you! Very helpful video.

  • @ahmedaj2000
    @ahmedaj2000 2 роки тому

    thank you for a detailed explanation

  • @aritrasarkar1557
    @aritrasarkar1557 5 років тому +1

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

  • @herculean6748
    @herculean6748 2 роки тому

    Thanks

  • @Zaii_3
    @Zaii_3 3 роки тому

    I love you bro keep it up!

  • @jeffbezos3942
    @jeffbezos3942 3 роки тому +1

    Does it also work for single letters?

    • @ragnarlothbrok367
      @ragnarlothbrok367 2 роки тому

      Single letter string is fine, but single char is not

  • @ahmadaboajineh6348
    @ahmadaboajineh6348 3 роки тому

    thank you

  • @cond6920
    @cond6920 4 роки тому +1

    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?

    • @accessdenied9393
      @accessdenied9393 3 роки тому

      You don't have to have a C program. You can use "diff" command-line utility in Linux to perform this task so easily

    • @cond6920
      @cond6920 3 роки тому

      @@accessdenied9393 I get you, but it was 11 months ago xD

    • @cond6920
      @cond6920 3 роки тому

      @@accessdenied9393 but, ty

  • @RahulKumar-no3rs
    @RahulKumar-no3rs 5 років тому +1

    Data structures pls

  • @dilipjain6899
    @dilipjain6899 5 років тому +1

    where is the value of strcmp stored?

  • @block8974
    @block8974 8 місяців тому

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

  • @akshatk1690
    @akshatk1690 2 роки тому

    string

  • @stevenshrii
    @stevenshrii 3 роки тому

    Sam

  • @sealandland3959
    @sealandland3959 3 роки тому

    what the hell is "furst" ?

  • @safwan096
    @safwan096 2 роки тому

    sky code?
    dafaq are you saying bruh

  • @178fahimahmed7
    @178fahimahmed7 4 роки тому

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

  • @quamzgraphix9826
    @quamzgraphix9826 5 років тому +2

    Thank you very much for this video...

  • @abhishek5212
    @abhishek5212 Рік тому

    Thank you so much ❤❤❤❤❤

  • @Gamer-rs6ow
    @Gamer-rs6ow 6 місяців тому

    Thank you