Комментарии •

  • @oussamajaballah7561
    @oussamajaballah7561 5 лет назад +101

    There's always an Indian guy who can make you understand that algorithm you seek . Tushar is definitely the best of them :)

  • @AntiGameZ
    @AntiGameZ 6 лет назад +1

    Good to see you again. The video is terrific as always.

  • @StanislavKozlovsk
    @StanislavKozlovsk 6 лет назад

    Super happy to see you back! Thanks so much

  • @girishgarg2816
    @girishgarg2816 4 года назад +11

    Simplification:
    You always take the nextTarget as the 0th element and then proceed to find the true nextTarget. However, this will fail if the nextTarget point and the leftmost point is same. In that case the while loop will end just after the first point as the nextTarget doesnot change its value and at the end of the loop when it sees nextTarget==starrt, it will break. In order to account for this you have addded the concept of collinear points too in your program. But it will be very easy if you just initialise nextTarget=start+1 or (start+1)%n (for overflows) always inside the while loop. This will simplify the code. Thank you

  • @dineshchoudhary8221
    @dineshchoudhary8221 6 лет назад

    Missed you so much!
    Welcome back.

  • @SonuSonu-tk5pk
    @SonuSonu-tk5pk 6 лет назад +32

    "hello friends my name is tushar "
    kaan taras jaate hai inn awaazen ko sunane ko
    happy to see u again

    • @tusharroy2525
      @tusharroy2525 6 лет назад +7

      thanks

    • @chetanraikwar3546
      @chetanraikwar3546 5 лет назад

      @@tusharroy2525 can you please make a video on *Suffix Array construction and applications* ? your suffix tree video was nice but you see, it's not so easy to implement. :( :( cover construction of Suffix array in nLogn or O(n) both version (DC3 algorithm) :/ also Persistent Segment Trees, Wavelet Trees etc :/ :/ *Suffix array a priority though ;)*

  • @jaideeppyne1880
    @jaideeppyne1880 6 лет назад +18

    Thanks, Tushar! For helping students across the globe to develop their knowledge in competitive programming :)

  • @kylcross
    @kylcross 6 лет назад +1

    I'm so happy you're back. If you ever do a meetup up let me know. lol. You're literally my hero.

  • @leandrogoncalvesdeoliveira9201
    @leandrogoncalvesdeoliveira9201 6 лет назад

    Tushar, your videos are awesome! Congratulations and thanks! :)

  • @ramcharanpalnati
    @ramcharanpalnati 6 лет назад +1

    Thank you Tushar ....Your videos have given me strength to get the Job....

  • @Klaster961
    @Klaster961 6 лет назад +9

    He is back again! :)

  • @shawncaojob
    @shawncaojob 6 лет назад

    Thank you Tushar. Great explanation!

  • @aditya.ishan27
    @aditya.ishan27 6 лет назад +1

    You are the best teacher ever.

  • @sauragra
    @sauragra 6 лет назад +1

    Thanks Tushar.
    Please do some System Design questions.

  • @tvbuff
    @tvbuff 2 года назад

    To be honest , I have been looking at various convex hull videos, everyone is just explaining the code part , no one is talking abt the intution .... You have explained it in the best way possible

    • @tvbuff
      @tvbuff 2 года назад

      I just wanna like this video from all my google accountss...........

  • @damchovic
    @damchovic 6 лет назад +1

    good to see you again!

  • @akshaysuman8168
    @akshaysuman8168 6 лет назад +3

    Hi Tushar, Good to see you back. Hope you will make more videos on dynamic programming.

  • @Kreamax
    @Kreamax 6 лет назад

    Great video, as always

  • @VivekShah98
    @VivekShah98 6 лет назад +2

    Can you please make video on Line Sweep Algorithm, I find it bit difficult to understand?

  • @AsliKalakar
    @AsliKalakar 6 лет назад

    thank you tushar sir , you are really amazing ..

  • @ievgengavrysh5831
    @ievgengavrysh5831 3 года назад

    Thx for the video and your work!
    Small typo: to find a vector ac (vector from point a to point c),
    you need to subtract ending point c from starting point a:
    (c_x - a_x, c_y - a_y).
    Otherwise you end up with vector pointing out to opposite direction.
    Because the same typo procedure was repeated for all vector, cross
    product will be the same (cos -1 * - 1 = 1 * 1 , -1 * 1 = 1 * -1).

  • @littlenarwhal3914
    @littlenarwhal3914 5 лет назад

    So, i havent done vector mathematics in math class yet, but from what i understand, the cross-product of two vectors is a line perpendicular to both of them. But since there are always two way a line can go in 3d space to be prependicular to the two other vectors, how do you decide which way it goes (negative or positive). I see you have a thumb rule, but could you mathematically explain this to me?

  • @maneeshrajan3778
    @maneeshrajan3778 5 лет назад +1

    great explanation sir. Please do this same for convex hull Graham's scan, line sweep.
    And if possible plz make video regarding parallel algorithms.

  • @aoi9716
    @aoi9716 6 лет назад +1

    Good to see you.

  • @arpitSheth1
    @arpitSheth1 5 лет назад

    Thanks, Tushar!

  • @uzairahmed1359
    @uzairahmed1359 Год назад

    in order to maintain points along the boundary in the same order, should we sort the collinear points in order of distance from the current point before adding to the results?

  • @harisridhar1668
    @harisridhar1668 2 года назад

    @13:55 Would it have any impact to always set "Point nextTarget" as "start" instead of "points[0]"? This has probably been a part confusing me since I struggled to intuit how the Jarvis March algorithm is guaranteed convergence, and, is guaranteed to find only those boundary points as well.

  • @marcusseidowski3320
    @marcusseidowski3320 5 лет назад +1

    Hey, great video. I'm looking for Gift wrapping algorithm in three dimensions. Do you have any hints oder advices on how I can trasfer 2d to 3d solution?

    • @rajjagtap7737
      @rajjagtap7737 9 месяцев назад

      Instead of a line, take a plane and find whether any point lies above that plane. Definitely a pretty complex code but could be an interesting solve.

  • @justinesdepiscis343
    @justinesdepiscis343 5 лет назад

    Fantastic! What an explanation!! I suscribe lml

  • @VishalBhartivisu
    @VishalBhartivisu 6 лет назад

    How do u make such a tough question so easy to understand...... Hats off...

  • @ritukaushik1717
    @ritukaushik1717 6 лет назад

    hi Tushar, can you do a video for "LRU cache" problem?

  • @chamilarathnayake
    @chamilarathnayake 6 лет назад

    Do a video tutorial about "Treaps" insertion and deletion. There are not much videos related to that.

  • @KeithSloan52
    @KeithSloan52 5 лет назад

    Is there a similar algorithm for a 3D hull?

  • @Scy
    @Scy 6 лет назад +3

    Great explanation of convex hull. Though the second part was bugging my OCD sensors.
    I think you've got some calculation errors. Vector AB is , whereas you have written it as , which is in fact the vector BA. Same with AC and AD, which you have turned into CA and DA. By coincidence the cross product is the same when you reverse both, but you would have trouble if you used those vectors individually for other things.
    Also a note on the cross product that is useful to know (maybe). Cross product is strictly a 3-dimensional vector operation, but we are "hacking it" in two dimensions by assuming z=0 and then returning the resulting cross product's z value as a scalar to determine the angular direction. Because the input z-values are 0, the output x and y values are automatically 0 (due to multiplication), so the only nonzero output result is the z value.

    • @lenordmelvix
      @lenordmelvix 5 лет назад +2

      Thanks Scy. Yes, the order should be reversed

    • @MGtvMusic
      @MGtvMusic 2 года назад

      Exactly what was bugging me .
      I started to doubt my years of intermediate Physics and mathematics haha.
      Thank you for the comment.

  • @SonuSonu-tk5pk
    @SonuSonu-tk5pk 6 лет назад +1

    boss is here

  • @naturesounds7153
    @naturesounds7153 5 лет назад

    Thanks Tushar

  • @utsavraychaudhuri696
    @utsavraychaudhuri696 4 года назад

    Brilliant!!! Just Brilliant!!!

  • @aliakram1834
    @aliakram1834 4 года назад

    So what i think is just figuring out least point in x direction (-ev) will define left bound , max point in x direction (+ev) will define the right bound.Similarly the least point in y direction (-ev) will define lower bound and positive y point will define upper bound.I dont what will be the data input format.

  • @nilaysheth3283
    @nilaysheth3283 3 года назад

    Which formula is used for finding cross product?

  • @shwetakumari-ms2xg
    @shwetakumari-ms2xg 4 года назад

    nice explanation.thanks

  • @aayush5474
    @aayush5474 3 года назад

    what's the point of pushing collinear points in result? Aren't they redundant for convex hull?

  • @varunaggarwal1995
    @varunaggarwal1995 6 лет назад

    Thanks buddy😃

  • @holyshit922
    @holyshit922 4 года назад

    I found code for Jarvis march on one of the russian sites This code is written in my favourite programming language
    On wikipedia code for Monotone chain can be found Monotone chain can be treated as simplified Graham's scan
    I had to introduce node counter to my doubly linked list to rewrite code for Monotone chain from wikipedia
    It was quite easy to rewrite code for Jarvis march from russian site

  • @afrozasultanakakon
    @afrozasultanakakon 6 лет назад

    I suppose it would be better to use collinearPoints.clear() in order to reset the collinear points.

  • @sadraxis
    @sadraxis 4 года назад

    love you, thanks

  • @ignaciocalafate6605
    @ignaciocalafate6605 5 лет назад

    This algorithm is based on the technique called greedy?

  • @SiddharthKulkarniN
    @SiddharthKulkarniN 6 лет назад

    Super useful

  • @SunggukLim
    @SunggukLim 6 лет назад

    Hi Tushar, Thank you for providing nice video. But it would be better if you have a nice mic.

  • @navanshu8703
    @navanshu8703 6 лет назад

    hi tushar , can you talk something abt your experience working at apple , not usual algo stuff .

    • @tusharroy2525
      @tusharroy2525 6 лет назад

      +Navanshu unfortunately can't. There is NDA.

  • @piyushkumar-wg8cv
    @piyushkumar-wg8cv Год назад

    I am not getting why you used set to store result instead of array or vectors

  • @piyushnarula3592
    @piyushnarula3592 4 года назад

    you cannot use set as it is for storing point object.

  • @SonuSonu-tk5pk
    @SonuSonu-tk5pk 6 лет назад +3

    sir if u ever get free time please add videos on geomertic algorithms and advanced trees algorithms

    • @tusharroy2525
      @tusharroy2525 6 лет назад +2

      which geometric algorithms?

    • @SonuSonu-tk5pk
      @SonuSonu-tk5pk 6 лет назад +2

      Thanks for the concern sir...
      please make videos on line sweeping ,bipartite matching and light decomposition algorithm

  • @konosh93
    @konosh93 4 года назад

    Tushar is great

  • @jarjeguzman5676
    @jarjeguzman5676 5 лет назад

    Thanks

  • @sakshamrajseth3288
    @sakshamrajseth3288 6 лет назад

    Thanks, Sir for this nice video. Can you please help by making a video on Sweep line algorithm. Thanks in advance :)

  • @mehranjalali5023
    @mehranjalali5023 5 лет назад

    Tushar for the vector ab the correct value would be b-a instead of a-b please refer to math.stackexchange.com/questions/1703120/calculating-vector-ab-from-vector-a-and-b. The result is the same since you compute all of them wrong or with a factor of -1.

  • @ArtyomPalvelev
    @ArtyomPalvelev 4 года назад

    Wait a sec, cross-product is a vector, not a number!

  • @greenitupp
    @greenitupp 6 лет назад

    Need Graham and scan

  • @ashishsinha8893
    @ashishsinha8893 6 лет назад +2

    sir I want to know learning to many language is important ya data structure and algorithm is more important with implemention...

    • @SonuSonu-tk5pk
      @SonuSonu-tk5pk 6 лет назад +1

      if u r interested in competitive programming or targeting a good company ds and algos are must...
      language is just a way to transfer ur thoughts to computer .. if u know c++ then try to make ur STL as good as possible ...and then implement try to implement these algorithms...in the free time try to learn java and php

    • @ashishsinha8893
      @ashishsinha8893 6 лет назад +1

      thanks buddy

  • @sadmanahmmed2214
    @sadmanahmmed2214 6 лет назад

    graham scan plzz

  • @pacmaybz
    @pacmaybz 4 месяца назад

    I don't understand, shouldn't the cross product be in 3d only? you're performing the calculation to get the determinant here

    • @pacmaybz
      @pacmaybz 4 месяца назад

      if I use the cross product formula setting the 3rd component to 0 it doesn't work

  • @harpalsinhjadeja2568
    @harpalsinhjadeja2568 5 лет назад

    make graham's algo also

  • @prashantgupta6885
    @prashantgupta6885 3 года назад

    I think he lost his password...WHYYYY? Please make more videos

  • @markriad3910
    @markriad3910 5 лет назад

    how can i modify this to get only the exterior points only ?

  • @aayushneupane5211
    @aayushneupane5211 4 года назад

    you are not a good teacher though you know things. thanks for sharing

  • @jeffpeng1118
    @jeffpeng1118 3 года назад

    hit like if u came to this video from UW CS341 also lmao

  • @ramandavid2047
    @ramandavid2047 6 лет назад

    plllll-zzzzzzzz sir hindi me Lecture dea keje

  • @ashishsinha8893
    @ashishsinha8893 6 лет назад

    I know c++