Dissecting FAANG Interview Questions

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

КОМЕНТАРІ • 40

  • @kimhyr
    @kimhyr 2 роки тому +13

    After watching multiple videos by you, I keep asking myself this question: "is this guy a well-established competitive programmer?" I tend to always ask myself this during the introduction of your videos.

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

    thank you for these videos! as an entry level coder, who only knows his way around java, these videos are great to expand the knowledge !

  • @shoooozzzz
    @shoooozzzz 2 роки тому +4

    Awesome walkthrough on your solutions.
    Confirming the first question is still being asked. Just got it yesterday.

  • @alok1819
    @alok1819 2 роки тому +11

    g0d level explaination , thank u for such great content ❤️❤️

  • @jez2718
    @jez2718 2 роки тому +1

    An idea for how one could optimise problem 1 further:
    You don't need to consider all of the 0s in the grid as potential 0s to flip. The only zeros that matter are the ones which are adjacent to a 1 (i.e., that lie in the exterior boundary of your connected components of 1s). And you can find all of these as you are doing your search that finds the components: every time one of the neighbours you encounter is a 0, you record the coords of that 0 and that the 0 was adjacent to the current component.
    So at the end of your search you have the size of each component, and for each boundary 0 you have a list of components which that 0 is adjacent to. Then for each such 0 you compute 1 + sum of sizes of adjacent components, and output the max.
    If the number of boundary 0s is O(n^2) this will be slower (though still O(n^2)), but if it is say O(n) this approach should be much faster. Consider a grid which is almost all 0s, you really don't want to try flipping all of them.

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

    Congrats for growing up the channel, you're such a good motivation

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

    Holy that lower bound set is huge. I can solve many problems with this idea. Thanks 😊

  • @aries3690
    @aries3690 2 роки тому +1

    I really loved your step by step solution to the Amazon question! Thanks for sharing

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

      I'm glad the solution made sense to somebody, lol. When asked those mathy algo questions, my answer is usually a blank stare

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

    Thanks a lot Colin,
    Kindly keep making these type of videos, your explanation is quite good.

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

    I'll watch it again later. Good job Colin!

  • @luanlucas8605
    @luanlucas8605 2 роки тому +1

    Awesome content! Found your channel not long ago and had to subscribe. Please keep up the great work!

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

    This is very easy understand . Please continue making more explanation videos

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

    The one and only cp best channel.....Keep growing up bro.....Soon this channel will be one of the best cp channel in the world.....This channel also now on fire🔥

  • @wesleyso0
    @wesleyso0 2 роки тому +1

    Loved the video, thanks Colin!

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

    The merge sorted arrays actually now asks for a O(log(m+n)) solution ,using binary search its kinda hard

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

    Thank you for always sharing the good stuff.. 🙏🙏

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

    Woah! This is awesome! Thanks for making this :)

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

    Yay!!! I subscribed just so you would make this video. Thanks!!!

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

    How do you generalize?
    I mean, I could memorize the solutions or link the solutions to specific problem - but you seem to actually solve it from first seeing the problem.

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

    Can you apply for jobs and interview for fun just to see their jaw drop as soon as start coding up the solution

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

    Wow, I didn't understand any of this and I'm trying to get an entry level job/internship coming from a business background. I took a bootcamp for web development using javascript, css, and html and then some back-end work using mongoDB and this wasn't enough for anyone to give me a call back. If this is the level for FANG, where do I start for beginner level jobs? Do you have a job?

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

      Start out with Data Structures, then move on to Algorithims, to understand the stuff for the interviews.
      To get in the door, you need to improve your resume, there is tons of resources on the internet on how to make a good resume for a coding job, I'd check out cracking the coding interview, reddit, and use google as well.
      It probably would be wise to build a project with front-end and back end, or a really good idea would be is find a certain company you're interested in, see what their stack is, and make a project with that same stack.
      Good luck!

    • @ColinGalen
      @ColinGalen  2 роки тому +8

      Just a note, I went out of my way to choose some of the hardest FAANG questions from the lists I found. So not everything will be this hard.
      I've never actually applied for a job/internship, so I don't know what it's really like, but I would imagine it's on average way more reasonable than the questions in this video.

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

    Hi, do u think the reason for early success in cp is due to having good math background? It's popular opinion that those who achieve success in contest usually already have good math skills?

    • @ColinGalen
      @ColinGalen  2 роки тому +6

      Coming in with a strong math background would definitely help, since mathematical reasoning can be a huge factor in solving these kinda of problems. That being said, if you don't have such a background, you can still learn the necessary reasoning and be able to succeed.

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

      Many top competitive programmers that I know of also competed in the Math Olympics (or other math contests) when they were younger. I don't think it's a coincidence that they also happen to dominate cp. Though, there is also many other factors other than just having math experience.

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

    not necessarily related, but what do you do to grow out and maintain your hair

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

    Cant we just Use Union find in Problem 1?

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

    as someone who "knows how to program", I don't know how to program.

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

    I'm a novice as far as coding algorithms go, but I have a strong background in mathematics and I found the Amazon problem to be trivially easy. The number of ways you can write an integer as a sum of consecutive integers is the same as the number of odd factors that it has because the average of an odd number of consecutive integers is an integer but not for an even number. If I could relate the other problems to mathematics more easily, my ability to develop new or use existing algorithms would be dramatically improved. Does anyone have any advice on how I can establish this relationship and connect the two fields in my brain? What's the relationship between computer science algorithms and mathematics, in general?

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

    👍👍👍

  • @kunalsanjaybutiya5944
    @kunalsanjaybutiya5944 2 роки тому +1

    You are girl or boy