Sleepy Cracker
Sleepy Cracker
  • 1 093
  • 125 759
#LeetCode 32 | Longest Valid Parentheses #Java
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing
Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
zhlédnutí: 12

Video

#LeetCode 750 | Number Of Corner Rectangles #Java
zhlédnutí 5Před 16 hodinami
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 1708 | Largest Subarray Length K #Java
zhlédnutí 2Před 16 hodinami
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 2727 | Is Object Empty #Typescript
zhlédnutí 3Před 16 hodinami
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 1421 |. NPV Queries #SQL
zhlédnutí 4Před 14 dny
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 3005 | Count Elements With Maximum Frequency #Java
zhlédnutí 12Před 14 dny
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 570 | Managers with at Least 5 Direct Reports #SQL
zhlédnutí 3Před 14 dny
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 1784 | Check if Binary String Has at Most One Segment of Ones #Java
zhlédnutí 5Před 14 dny
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 2989 | Class Performance #SQL
zhlédnutí 2Před 14 dny
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 3000 | Maximum Area of Longest Diagonal Rectangle #Java
zhlédnutí 2Před 14 dny
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 1571 | Warehouse Manager #SQL
zhlédnutí 3Před 14 dny
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 2390 | Removing Stars From a String #Java
zhlédnutí 17Před 21 dnem
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 1633 | Percentage of Users Attended a Contest #Java
zhlédnutí 8Před 21 dnem
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 2923 | Find Champion I #Java
zhlédnutí 8Před 21 dnem
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 2570 | Merge Two 2D Arrays by Summing Values #Java
zhlédnutí 17Před 21 dnem
Questions in English: docs.google.com/spreadsheets/d/1QNSEok-WD4LCPTrZlqq5VVTX0NbXQf27WUjkGi3aBu0/edit?usp=sharing Questions in Mandarin: docs.google.com/spreadsheets/d/1aMCmSLucm7I_7BIRz1SqHy8c1D9h_6M8XAkrqWXSy8Y/edit?usp=sharing
#LeetCode 1874 | Minimize Product Sum of Two Arrays #Java
zhlédnutí 25Před 21 dnem
#LeetCode 1874 | Minimize Product Sum of Two Arrays #Java
#LeetCode 1083 | Sales Analysis II #Java
zhlédnutí 17Před měsícem
#LeetCode 1083 | Sales Analysis II #Java
#LeetCode 2176 | Count Equal and Divisible Pairs in an Array #Java
zhlédnutí 17Před měsícem
#LeetCode 2176 | Count Equal and Divisible Pairs in an Array #Java
#LeetCode 2853 | Highest Salaries Difference #Java
zhlédnutí 10Před měsícem
#LeetCode 2853 | Highest Salaries Difference #Java
#LeetCode 3024 | Type of Triangle #Java
zhlédnutí 12Před měsícem
#LeetCode 3024 | Type of Triangle #Java
#LeetCode 3014 | Minimum Number of Pushes to Type Word I #Java
zhlédnutí 12Před měsícem
#LeetCode 3014 | Minimum Number of Pushes to Type Word I #Java
#LeetCode 2960 | Count Tested Devices After Test Operations #Java
zhlédnutí 12Před měsícem
#LeetCode 2960 | Count Tested Devices After Test Operations #Java
#LeetCode 1865 | Finding Pairs With a Certain Sum #Java
zhlédnutí 8Před měsícem
#LeetCode 1865 | Finding Pairs With a Certain Sum #Java
#LeetCode 2937 | Make Three Strings Equal #Java
zhlédnutí 7Před měsícem
#LeetCode 2937 | Make Three Strings Equal #Java
#LeetCode 2352 | Equal Row and Column Pairs #Java
zhlédnutí 15Před měsícem
#LeetCode 2352 | Equal Row and Column Pairs #Java
#LeetCode 1661 | Average Time of Process per Machine #SQL
zhlédnutí 7Před měsícem
#LeetCode 1661 | Average Time of Process per Machine #SQL
#LeetCode 659 | Split Array into Consecutive Subsequences #Java
zhlédnutí 9Před měsícem
#LeetCode 659 | Split Array into Consecutive Subsequences #Java
#LeetCode 1353 | Maximum Number of Events That Can Be Attended #Java
zhlédnutí 18Před měsícem
#LeetCode 1353 | Maximum Number of Events That Can Be Attended #Java
#LeetCode 2210 | Count Hills and Valleys in an Array #Java
zhlédnutí 12Před měsícem
#LeetCode 2210 | Count Hills and Valleys in an Array #Java
#LeetCode 1089 | Duplicate Zeros #Java
zhlédnutí 23Před 2 měsíci
#LeetCode 1089 | Duplicate Zeros #Java

Komentáře

  • @i_techlover
    @i_techlover Před dnem

    Thank you...approach was easy to understand

  • @anadiru4382
    @anadiru4382 Před 3 dny

    Awesome explanation!!!

  • @sufijahan1573
    @sufijahan1573 Před 4 dny

    Thank you 😊

  • @tousifkhan510
    @tousifkhan510 Před 7 dny

    Good Effort, please keep it up.

  • @user-mk7qi6gc2m
    @user-mk7qi6gc2m Před 9 dny

    i did'nt understand the for each loop here, can you explain

  • @tommyls4357
    @tommyls4357 Před 21 dnem

    Very cool technique. Thank you :-)

  • @5577_SAYANADHIKARI
    @5577_SAYANADHIKARI Před měsícem

    U could provide a link to the codebase or preferably give the code in the comments. :)

    • @sleepycracker4732
      @sleepycracker4732 Před měsícem

      good advice, but I don't like to give away code like that.

  • @PhrogDaz
    @PhrogDaz Před měsícem

    Bruteforce method and 5 ms runtime :(

  • @psinity
    @psinity Před měsícem

    thanks a lot!

  • @11csepratikshaargulewar71

    If you are making video of something , shouldn't you be clear and well heard . additionally you should pronounce words properly .just a feedback after watching your video

    • @sleepycracker4732
      @sleepycracker4732 Před měsícem

      thanks for watching. I am making the video for myself. Best,

  • @Rajesh_100
    @Rajesh_100 Před měsícem

    Good Approach💯

  • @abhinvsinh
    @abhinvsinh Před měsícem

    Thank you for the code and the explanation. Keep up the good work.

  • @aayushmaantawer285
    @aayushmaantawer285 Před měsícem

    Best Explaination

  • @KamalSabanov
    @KamalSabanov Před měsícem

    thank you man :)

  • @dwivedishashank9
    @dwivedishashank9 Před 2 měsíci

    Dude, thanks!

  • @ganeshjaggineni4097
    @ganeshjaggineni4097 Před 2 měsíci

    NICE SUPER EXCELLENT MOTIVATED

  • @kapilpalanivel2309
    @kapilpalanivel2309 Před 2 měsíci

    Bro's cooking very quiet in silence

  • @rajshiromani727
    @rajshiromani727 Před 2 měsíci

    those keyboard clicks are so irritating

  • @AmitKumar-uu6dl
    @AmitKumar-uu6dl Před 2 měsíci

    Thank you bhaiya, it is very helpful 😊

  • @user-po1nt3gq5o
    @user-po1nt3gq5o Před 2 měsíci

    ❤me too lol

  • @sleepycracker4732
    @sleepycracker4732 Před 3 měsíci

    similar question: czcams.com/video/hwgZAy8oRRk/video.html

  • @sleepycracker4732
    @sleepycracker4732 Před 3 měsíci

    similar question: czcams.com/video/HVBxIP1zcPY/video.html

  • @sleepycracker4732
    @sleepycracker4732 Před 3 měsíci

    the old video can be accessed through here: czcams.com/video/rtkAsSUjpQ0/video.html However, youtube currently disable people to view it report: czcams.com/users/postUgkxRzAU91_3AwBrjd3otZb0lrKsueNfbiac

  • @hari7110
    @hari7110 Před 3 měsíci

    nice explanation!

  • @ShubhamSharma-sf8wk
    @ShubhamSharma-sf8wk Před 3 měsíci

    Bro get a decent mic

    • @sleepycracker4732
      @sleepycracker4732 Před 3 měsíci

      Apologies, it was crafted two years back. However, the setup wasn't prepared at that time.

    • @ShubhamSharma-sf8wk
      @ShubhamSharma-sf8wk Před 3 měsíci

      @@sleepycracker4732 No worries, great explanation tho

  • @DevMishra001
    @DevMishra001 Před 3 měsíci

    good solutions and easily understandable.

  • @razvi-uv5ki
    @razvi-uv5ki Před 3 měsíci

    awesome, keep it up!

  • @abishekc9478
    @abishekc9478 Před 3 měsíci

  • @CrashAddict60
    @CrashAddict60 Před 3 měsíci

    I really appreciate your channel 🙌. I'm going to start doing leetcode again this month

  • @ayush1072
    @ayush1072 Před 3 měsíci

    great logic bro ...

  • @tonyz2203
    @tonyz2203 Před 3 měsíci

    you use js now!

  • @tonyz2203
    @tonyz2203 Před 3 měsíci

    good

  • @tanmaymhaske7587
    @tanmaymhaske7587 Před 4 měsíci

    Best explanation with Diagram, was struggling to understand this problem

  • @devnull711
    @devnull711 Před 4 měsíci

    very good solution and explanation

  • @thisisnotok2100
    @thisisnotok2100 Před 4 měsíci

    This is a genius solution, I couldn't fathom a bit of this. I tried to do a sliding window and splice out from the window.

  • @weeniee29
    @weeniee29 Před 4 měsíci

    Can you explain it clearly

  • @sleepycracker4732
    @sleepycracker4732 Před 4 měsíci

    2 Pointer: czcams.com/video/BAKrAvGFL3Q/video.html HashMap: czcams.com/video/ze_viMxD9n8/video.html

  • @sleepycracker4732
    @sleepycracker4732 Před 4 měsíci

    DFS version1:czcams.com/video/KCaledGy-S8/video.html DFS version2: czcams.com/video/O9draJvnIFc/video.html BFS: czcams.com/video/eFRiufqFf2I/video.html

  • @jayeshtak2530
    @jayeshtak2530 Před 4 měsíci

    AWESOME

  • @sleepycracker4732
    @sleepycracker4732 Před 5 měsíci

    old version: czcams.com/video/IFmj-Jb3Hhg/video.html

  • @artone5841
    @artone5841 Před 5 měsíci

    if we iterate the bucket the tc is o(n) and than we iterate the list the tc is o(k) so why not ther tc of this soln is o(n*k), why its o(n) , if n is 9 and the k is 6 so u cant neglect the k

    • @sleepycracker4732
      @sleepycracker4732 Před 5 měsíci

      k is a given input which should be a constant in the question. However, I agree with you that the complexity of this solution is O(N*k).

  • @sleepycracker4732
    @sleepycracker4732 Před 5 měsíci

    old version: czcams.com/video/nglC6G23SOM/video.html

  • @jaatharsh
    @jaatharsh Před 5 měsíci

    Brillant explanation thanks buddy

  • @sleepycracker4732
    @sleepycracker4732 Před 6 měsíci

    old version: czcams.com/video/pxbyjog6BcQ/video.html

  • @sleepycracker4732
    @sleepycracker4732 Před 6 měsíci

    Array: czcams.com/video/v2HDOC8usew/video.html DP: czcams.com/video/ZR1TpHJnHq0/video.html

  • @sleepycracker4732
    @sleepycracker4732 Před 6 měsíci

    DFS: czcams.com/video/3jzDkW4_WTE/video.html BFS: czcams.com/video/P0xqYQoK3fs/video.html

  • @aminah.03
    @aminah.03 Před 6 měsíci

    Oh, a reminder I need to practice! Will check out your other videos!

  • @sleepycracker4732
    @sleepycracker4732 Před 6 měsíci

    BFS old version: czcams.com/video/lmoC2alK7nY/video.html DFS old version: czcams.com/video/EaWCmwsW_uc/video.html

  • @sleepycracker4732
    @sleepycracker4732 Před 6 měsíci

    old version1: czcams.com/video/ttOCXU2T_dE/video.html old version2: czcams.com/video/NGR2fZ3YAYA/video.html

  • @johnangelo2000
    @johnangelo2000 Před 6 měsíci

    Please explain why atMost(k) - atMost(k-1) needed? I didn't dig deep to understand it.

    • @sleepycracker4732
      @sleepycracker4732 Před 6 měsíci

      think about this way. what are the sub array you have when k = 1? using the example 1: Input: nums = [1,2,1,2,3], the answer should be: 5. [1],[2],[1],[2],[3] what if k = 2? the answer is 7. [1,2], [2,1], [1,2], [2,3], [1,2,1], [2,1,2], [1,2,1,2]. but this is the sub arrays after you cut down the k=1 sub arrays. if you don't subtract the sub arrays, you should have [1],[2],[1],[2],[3],[1,2], [2,1], [1,2], [2,3], [1,2,1], [2,1,2], [1,2,1,2]. these are the result we have for atMost(2) in order to get the count of sub array to 7, we must minus atMost(1) hope this helps

    • @johnangelo2000
      @johnangelo2000 Před 6 měsíci

      @@sleepycracker4732 Yes it was not intuitive enough for me to figure out (j-i+1) is doing what you mentioned.

    • @sleepycracker4732
      @sleepycracker4732 Před 6 měsíci

      that is how we get the length of the subarray. it would be clear enough if you draw the index on a paper

    • @johnangelo2000
      @johnangelo2000 Před 6 měsíci

      @@sleepycracker4732 Yes I went to paper and drew it and it turned out true and made sense. Thanks