300_are_queue's blog

By 300_are_queue, history, 2 years ago, In English

Things that I have heard of and know (imagine how many things I haven't even heard of):

  • Binary search

If you don't know at least 1 of these things and you are not red — you are doing it wrong. Stop learning useless algorithms, go and solve some problems, learn how to use binary search.

  • Vote: I like it
  • +382
  • Vote: I do not like it

| Write comment?
»
2 years ago, # |
  Vote: I like it -26 Vote: I do not like it

i don't know what it is, can u teach me?

»
2 years ago, # |
  Vote: I like it +33 Vote: I do not like it

Things that I haven't heard of and don't know (imagine how many things I have heard of):

Two pointers

If you know at least 3 of these things and you are red — you are doing it right. Continue learning useless algorithms, don't go and solve some problems, learn how to use FFT.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    I can't implement this algorithm. How do I use pointers in Python?

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it +20 Vote: I do not like it

      To use two pointers you have to think like two pointers. On early stages it's better to imagine that your friend is the first pointer and you are the second.

»
2 years ago, # |
  Vote: I like it +95 Vote: I do not like it

wtf bro, where does a taxi driver need a binary search?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +57 Vote: I do not like it

    To find a passenger of height h among n passengers standing in the sorted order of their heights.

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it +16 Vote: I do not like it

      wtf bro why does the driver have to give a damn about the height as long as they are not > 6.5 feet?

      • »
        »
        »
        »
        2 years ago, # ^ |
          Vote: I like it +13 Vote: I do not like it

        Maybe they are binary searching to find the person with a height of 6.5 feet :)

»
2 years ago, # |
  Vote: I like it +3 Vote: I do not like it

binary search is used in bitmasks only to find the count of (2)s in this mask

»
2 years ago, # |
  Vote: I like it +16 Vote: I do not like it

I'm just waiting for the day when I find a problem with my binary search implementation, then my list of "things I know" will finally be empty

»
2 years ago, # |
  Vote: I like it +15 Vote: I do not like it

Teach me this dark art you speak of. What is it capable of?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +124 Vote: I do not like it

    Let's say you have a list of girls (or boys?) that you like, sorted by how cool they are. Let's further assume that a person will not date you if they are too cool for you. Then you can use binary search to find the best person that will date you, only within a very few embarrassing attempts to ask somebody out.

»
2 years ago, # |
  Vote: I like it -58 Vote: I do not like it

Ok, that's obviously a lie because in 133492526 You used dp and number theory. And it is only one sumbission. P.s. I know it is a joke...

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +4 Vote: I do not like it

    You know, technically it could be the truth if he wasn't the real author of the code from that submission... Or he independently reinvented DP without knowing what it is... Or it was indeed just a joke.

»
2 years ago, # |
  Vote: I like it +11 Vote: I do not like it

it is so funny i forgot to laugh

»
2 years ago, # |
  Vote: I like it +8 Vote: I do not like it

umnik approves

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

I see, so that's exactly and the only reason I'm not purple, because I don't know Binary search

»
2 years ago, # |
  Vote: I like it +29 Vote: I do not like it

Things that I have heard of and know (imagine how many things I haven't even heard of):

If you don't know at least 1 of these things and you are not green — you are doing it wrong. Stop learning useless algorithms, go and solve some problems, learn how to use binary search.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +15 Vote: I do not like it

    lomien stop learning and reciting useless chinese data structure algorithms

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    The only thing I would insert here is how to read input data.