Count The Unique Elements In An Array | C Programming Example

แชร์
ฝัง
  • เผยแพร่เมื่อ 14 ต.ค. 2024
  • How to count the number of unique elements in an array using C. Source code: github.com/por.... Check out www.portfolioc... to build a portfolio that will impress employers!

ความคิดเห็น • 23

  • @shadow3961
    @shadow3961 ปีที่แล้ว +1

    Great to have you back. I hope all is well.

  • @steevenkenny9791
    @steevenkenny9791 ปีที่แล้ว

    Im just here literrally to write this comment because even if I didnt watch.. im sure that it is.. great work sir...

  • @Razik_058
    @Razik_058 ปีที่แล้ว +3

    Your hard work will pay you one day ☺️

    • @PortfolioCourses
      @PortfolioCourses  ปีที่แล้ว +4

      Thank you for the support, I appreciate it. 🙂

  • @blablabla8133
    @blablabla8133 ปีที่แล้ว

    BEST C tutorial I have ever seen and I love your voice

    • @PortfolioCourses
      @PortfolioCourses  ปีที่แล้ว

      Thank you so much, I'm really glad that you enjoyed it! 🙂

  • @qcnck2776
    @qcnck2776 ปีที่แล้ว

    Good to see another video. Hope the baby 👶is sleeping as well as expected and Mom and Dad are getting a little bit of sleep too.

    • @PortfolioCourses
      @PortfolioCourses  ปีที่แล้ว +1

      Thanks! Baby and mom are doing well, and dad tries to get as much sleep as he can. :-)

  • @uzairbukhari99
    @uzairbukhari99 ปีที่แล้ว

    Amazing C programs. They help me a lot during my C programming class

    • @PortfolioCourses
      @PortfolioCourses  ปีที่แล้ว

      Thank you Uzair, I'm really glad to hear these videos helped you during your C programming class... that's exactly why I love to make these videos! :-)

  • @JerJerSC
    @JerJerSC ปีที่แล้ว

    I Learned a lot from this Channel. Thank you very much.

    • @PortfolioCourses
      @PortfolioCourses  ปีที่แล้ว

      You're very welcome Jerwin, I'm really glad that you've learned a lot from this channel. :-)

  • @nitishkumar99147
    @nitishkumar99147 หลายเดือนก่อน

    Thank you sir.

  • @dtikvxcdgjbv7975
    @dtikvxcdgjbv7975 ปีที่แล้ว

    And I was expecting whole the time the block of commands to calculate the length, why it takes him so long to write it 😃
    Nice work

  • @matpietrzak
    @matpietrzak ปีที่แล้ว

    Nice job! It looks like n^2 complexity. Is it possible to make it more efficient?

    • @PortfolioCourses
      @PortfolioCourses  ปีที่แล้ว +1

      Yes, there's a few ways. :-) One quick optimization would be to 'break' in the inner-loop as soon as a match is found. Another optimization would work if we knew the range of ints... we could create an array of bools (one for each possible int) and set the index for an int to true if a match is found, then checking to see if a match is found is a matter of checking that index, making the problem O(n) complexity (but taking up more space too).

  • @baotang6436
    @baotang6436 10 หลายเดือนก่อน

    anyone help me
    if(!match_found) is if(match_found == false)
    is it right ?

  • @poisonmods
    @poisonmods ปีที่แล้ว

    Ur back

    • @PortfolioCourses
      @PortfolioCourses  ปีที่แล้ว

      Yep! :-) Hoping to get back to posting at least semi-regularly now.

  • @OmarAhmed-nb4mv
    @OmarAhmed-nb4mv ปีที่แล้ว

    Great