May Leetcode Challenge Speedrun LIVE

leaderboard: kostka.dev/leetcode-speedrun/
30 coding interview problems from May Leetcode Challenge in 1 hour? Let's try!
leetcode.com/explore/challeng...
Subscribe for more educational videos on algorithms, coding interviews and competitive programming.
- Github repository: github.com/Errichto/youtube
- Twitch live streams: / errichto
- FB and Twitter: / errichto & / errichto
- Frequently Asked Questions: github.com/Errichto/youtube/w...
- Competitive Programming Discord: discordapp.com/invite/UzaURu7
#Coding #Programming

Пікірлер: 67

  • @Errichto
    @Errichto4 жыл бұрын

    It starts at 38:56! I'm mentally exhausted now and going to play some Rocket League. I will update this comment later with info about future streams.

  • @fosres

    @fosres

    4 жыл бұрын

    I think its interesting how even you sometimes play video games on your downtime. Did video games make you interested in coding? Please let us know in a future video how you got interested in programming in general.

  • @mayankraj6511

    @mayankraj6511

    4 жыл бұрын

    sir,please make an editorial on sorted vase (codechef may challenge) problem

  • @SiLLyIITian

    @SiLLyIITian

    4 жыл бұрын

    Can you make a tutorial on this problem? . If you find it interesting www.codechef.com/JAN20B/problems/CHEFPSA

  • @cypherllc7297

    @cypherllc7297

    4 жыл бұрын

    whats your tier in rocket league

  • @avinashyadav1
    @avinashyadav14 жыл бұрын

    Watching you doing these problems in an hour I am motivated enough to do this in a day. This Saturday it's going to be fun.

  • @boco6969
    @boco69693 жыл бұрын

    Coming back to old videos to watch it again. So fun to watch how you tackle each problems

  • @fosres
    @fosres3 жыл бұрын

    Green screen looks great Errichto! Keep up with the good work.

  • @tudoriacob9632
    @tudoriacob96323 жыл бұрын

    Can’t believe that at the problem “remove K digits” I knew it was a stack and errichto didn’t!

  • @almuhimen8023
    @almuhimen80234 жыл бұрын

    Even errichto gets TLE.

  • @mohammedjawahri5726
    @mohammedjawahri57264 жыл бұрын

    does making the input a const reference speed things up? Making it a reference obviously does but I thought const only told the compiler to do runtime checks (basically announcing intent that this is a read only parameter) Are there any optimizations that would speed up const x& vs x&?

  • @apurvpatani
    @apurvpatani4 жыл бұрын

    Damn, I would like to see tourist vs william for easy problems, that would be interesting

  • @gautamverma1203
    @gautamverma12034 жыл бұрын

    could you please give a you workspace setup tour... that would be great!

  • @anoubhav
    @anoubhav4 жыл бұрын

    Can somebody explain Errichto's solution (the algorithm) to the maximum sum circular subarray at 1:12:49? I am aware of the kadane's algorithm (find max and min) solution. But here he used a stack. Thanks.

  • @apurvpatani
    @apurvpatani4 жыл бұрын

    Yeah, it wasss fun to watch man :)

  • @SARANSASIDHARAN1
    @SARANSASIDHARAN14 жыл бұрын

    Nice video. For perfect square problem, sqrt was not allowed.

  • @BrianBin
    @BrianBin4 жыл бұрын

    I like your background, what theme name is that?

  • @divyenayy5973
    @divyenayy59734 жыл бұрын

    how to use your imie(debugger) function for arrays

  • @aswathjacob
    @aswathjacob4 жыл бұрын

    Most people like us run our code first. This guy only clicks submit!!!. Man, I need that level of confidence

  • @mikemihay
    @mikemihay4 жыл бұрын

    Can you do also for Python?

  • @sahajchoudhary5164
    @sahajchoudhary51644 жыл бұрын

    superb man!!

  • @hrithiksytle5058
    @hrithiksytle50584 жыл бұрын

    You Killed it bro 👍👍

  • @rohan8arora
    @rohan8arora3 жыл бұрын

    Took me 4 days to complete what errichto did in 1-2 hours :P

  • @sahilsrivastav1203
    @sahilsrivastav12034 жыл бұрын

    Hey Erichto, would you like to make a video on how you think when you get a new problem. How do you think that which algorithm will be used in order to solve that problem. As a college student that video will be of great help. Thank you.

  • @darthmath1071

    @darthmath1071

    4 жыл бұрын

    practice

  • @NotesNaka
    @NotesNaka4 жыл бұрын

    Great video 👍

  • @yashrastogi3726
    @yashrastogi37264 жыл бұрын

    Nice work bro

  • @benniebees
    @benniebees4 жыл бұрын

    43:05 what about using the bitwise exclusive or operator (^) on num and another integer that has all bits 1. The result is the complement of num? So for a signed int, the value -1 has all bits set to 1. So you'd return num ^ -1; edit: I guess they want you to trim all the leading 0 bits from num. You could find the lowest power of 2 that is higher or equal num, then subtract num from that and you have the complement.

  • @imshafay

    @imshafay

    4 жыл бұрын

    in python you can just simple use string then use replacment with 0 to 1 and 1 to 0 (using hashmap replacement)

  • @HDbIce-oj3wv
    @HDbIce-oj3wv4 жыл бұрын

    Hi Errichto. I just finished the c++ tutorial on youtube. But my doubt is should I learn the stl library now or start with competitive programming on hackerrank? Do reply🙂

  • @jas4768

    @jas4768

    4 жыл бұрын

    Do both

  • @florinchis4684
    @florinchis46843 жыл бұрын

    At 53:23 (Valid Perfect Square problem) aren't you supposed not to use sqrt function at all (The notice in the problem denies use of built-in function sqrt()) ?

  • @vaibhav.polska

    @vaibhav.polska

    2 жыл бұрын

    He did it for speedrun.

  • @buckbd187
    @buckbd1874 жыл бұрын

    make tut for june challenge atleast those are medium & hard

  • @sokhibsaid
    @sokhibsaid4 жыл бұрын

    These kinds of challenges are entertaining and fun, but do not understand me wrong I think most of us are here to learn. If I don't understand your code, why am I here right? For example, I didn't understand your code for the Maximum sum circular subarray and someone else in comments as well. I think it would be better problems with explanations. Anyway, you are doing a great job thanks.

  • @cliffcrosland

    @cliffcrosland

    3 жыл бұрын

    I think I understand the Maximum Sum Circular Subarray solution a bit. Not easy to explain in a KZread comment, but I'll give it a try. I believe it actually might be better to think of the data structure used in the solution as a queue instead of a stack. When the "first" variable is incremented, it's like the bottom of the stack is being removed, which is like popping the front of a queue. I'll call it a stack though to stay consistent with the solution. The stack contains prefix sums that are generated as we walk along the doubled array. The stack represents a sliding window of prefix sums. The window size can be at most "n". We remove the bottom of the stack (i.e. pop the front of the queue) to avoid exceeding that window size. Why do we run the "while" loop to pop prefix sums from the top of the stack? This happens when "a[i]" is negative or zero, causing "curr_prefix" to become less than or equal to one or more prefix sums at the top of the stack. When we pop a pair "(i, prefix_sum[i])" from the top of the stack, we are basically saying that we never want to use "i" as the left boundary of our window. When we are choosing the left boundary of our window, we will skip over those values of "i" because those will lead to strictly smaller answers. For example, if "prefix_sum[i] >= curr_prefix", then "curr_prefix - prefix_sum[i]" is going to be zero or negative. We want the largest possible answer, so it's better to skip that candidate. I did not explain that last part well, but hopefully this helps somewhat.

  • @sokhibsaid

    @sokhibsaid

    3 жыл бұрын

    @@cliffcrosland thanks

  • @memesmacha61
    @memesmacha614 жыл бұрын

    Can you please suggest which language is best for data structure and algorithm please suggest me..!!

  • @almuhimen8023

    @almuhimen8023

    4 жыл бұрын

    The language you know the most or most comfortable with

  • @dragon_warrior_

    @dragon_warrior_

    4 жыл бұрын

    @@almuhimen8023 bhai koi bhi ek chalu to kar pehle

  • @almuhimen8023

    @almuhimen8023

    4 жыл бұрын

    @@dragon_warrior_ keya matlab apka?

  • @RaushanKumar-ol2cz
    @RaushanKumar-ol2cz4 жыл бұрын

    Please make video on the problems of codechef may long challenge of Div 1.

  • @sourabhkhandelwal1568

    @sourabhkhandelwal1568

    4 жыл бұрын

    He doesn't compete on Codechef.

  • @coldatom404
    @coldatom4042 жыл бұрын

    And people like me take one day to solve one problem.

  • @Dominik-ls9nw
    @Dominik-ls9nw4 жыл бұрын

    Alter hat der einen Dachschaden

  • @mdzaid5925
    @mdzaid59254 жыл бұрын

    Man i cannot even watch and type at the same speed

  • @Anonymous____________A721

    @Anonymous____________A721

    7 ай бұрын

    😂😂😂😂😂😂

  • @ajajaj2
    @ajajaj24 жыл бұрын

    wow

  • @ChandraShekhar-by3cd
    @ChandraShekhar-by3cd3 жыл бұрын

    @Errichto One SMALL suggestion would be to give the PROBLEM LINK for leetcode along with the TIMESTAMP to quickly navigate to the problem. This will allow a more easy way to find which problems are being discussed in the video as it is longer video , people may find it difficult to check which problems are being discused and at what timestamp...Thanks Hope to see those changes in the UPCOMING VIDEOS.

  • @adityasirna7467
    @adityasirna74674 жыл бұрын

    Finally got Alex's live stream : www.twitch.tv/videos/637967738

  • @prahalad4651
    @prahalad46514 жыл бұрын

    You are given ordered triples (a, b, c) you have to convert it to (x, y, z) using only addition and multiplication of any integer. Note that a, b,c, x, y, z can be any integers it can be argued that maximum number of steps would be 3 for converting as we can add an integer to each of them but you need to find the minimum number of steps. Sir I am your great fan please reply soon. I an stuck here for a long time.

  • @amey7064

    @amey7064

    4 жыл бұрын

    This is from the June Long Challenge. It is live right now. None shall tell you the solution. Find it yourself or read editorials after the contest.

  • @prahalad4651

    @prahalad4651

    4 жыл бұрын

    @@amey7064 kudos, I solved it. I asked it in shear frustration but later I got an idea.

  • @kousikmitra7069
    @kousikmitra70694 жыл бұрын

    Didn't understood how firstUniqueChar() worked!

  • @cliffcrosland

    @cliffcrosland

    3 жыл бұрын

    He goes back and fixes it at 46:06

  • @cliffcrosland

    @cliffcrosland

    3 жыл бұрын

    btw, this is so fun to watch! thank you Errichto!

  • @ashutoshrajput9515
    @ashutoshrajput95154 жыл бұрын

    At Errichto - you are coding soo fast Please slow it down

  • @alexander6233
    @alexander62334 жыл бұрын

    kzread.info/dash/bejne/Yq2Zz7iRdKXIqco.html leetcode.com/explore/challenge/card/may-leetcoding-challenge/534/week-1-may-1st-may-7th/3320/ how that code for Day 5 (First Unique Character in a String) was Accepted? You just add each string char to set and then check if the set does not contain each char from same string. They all should be there and method should always return -1. I have submitted same program and it was not accepted. int firstUniqChar(string s) { set ss; for(char ch : s) { ss.insert(ch); } for(int i = 0; i if(!ss.count(s[i])) { return i; } } return -1; }

  • @yashkhatwani3198

    @yashkhatwani3198

    2 жыл бұрын

    same doubt

  • @abhishekmr8876
    @abhishekmr88764 жыл бұрын

    .think()

  • @user-kw2if3en4p
    @user-kw2if3en4p4 жыл бұрын

    你们这是在干嘛?写的啥?

  • @ashutoshrajput9515
    @ashutoshrajput95154 жыл бұрын

    But the thing is being a programmer will not make you rich

  • @IQ-iv7tj
    @IQ-iv7tj3 жыл бұрын

    love you =)))) i am gay =))) do you like that??? =))))

  • @sonido0
    @sonido03 жыл бұрын

    william better than you bro