Winning LeetCode Weekly Contest 201

  Рет қаралды 127,668

William Lin

William Lin

Күн бұрын

Didn't expect a win... But I'll take it!
leetcode.com/contest/weekly-c...
Second channel (William Lin ++): / @williamlinpp4187
Website: williamlin.io/
Instagram: / tmwilliamlin168
Twitter: / tmwilliamlin168
Discord: williamlin.io/discord

Пікірлер: 159
@TrenBlack
@TrenBlack 3 жыл бұрын
William Lin in a few years: "Didn't expect to recieve a Turing award... But I'll take it!"
@harryguanous7198
@harryguanous7198 3 жыл бұрын
Hello Tren Black, when did you get here.
@pearlinperil9985
@pearlinperil9985 2 ай бұрын
trennnn🥹
@rayanbaida
@rayanbaida 3 жыл бұрын
this guy solves the questions faster than i can read them
@samkarpa4937
@samkarpa4937 3 жыл бұрын
😂😂🤣
@jhonx1420
@jhonx1420 3 жыл бұрын
LoL true
@FFMAN3
@FFMAN3 3 жыл бұрын
That's because he has done so many similar questions, he recognizes a problem with first word and doesn't read whole question
@VrickzGamer
@VrickzGamer 3 жыл бұрын
@@dsa5821 No Red code is William Liner
@nightcoder5k
@nightcoder5k 2 жыл бұрын
You can get ahead of him by pausing the video and reading. LOL
@AaronHe
@AaronHe 3 жыл бұрын
10:28 I enjoyed 6th place for one second.
@vancedstone
@vancedstone 3 жыл бұрын
Hey that's still really good!
@AaronHe
@AaronHe 3 жыл бұрын
@@vancedstone Yeah dude, I finished the third problem, looked on the leaderboard, and freaked out. Tried to solve problem 4 as fast as possible but failed.
@vancedstone
@vancedstone 3 жыл бұрын
@@AaronHe Lol I would probably freak the heck out too and mess up the next problem.
@michaellakouadio6133
@michaellakouadio6133 3 жыл бұрын
Hey, i want to learn how to code but don't know where to start. Do you have any tips? Thank you!
@rexgamingcsgoandmore4833
@rexgamingcsgoandmore4833 3 жыл бұрын
damn bro good job
@jacked_asian
@jacked_asian 3 жыл бұрын
what a trooper to do this while mom vacuums
@kishorprasad3817
@kishorprasad3817 3 жыл бұрын
Hey William, Lately I observed that you are taking part in almost all leetcode contest, kindly upload videos whether you win or not, even if you don't perform well, we learn how you debug things and come to optimised solution.. Your videos are quite helpful. Thanks for helping us out.
@pleasesirmorevideos4684
@pleasesirmorevideos4684 3 жыл бұрын
he did not upload in the bit wise weekly contest when he came 12th :(
@vtvtify
@vtvtify 3 жыл бұрын
Meanwhile Errichto uploading his last place rounds on topcoder..
@kueen3032
@kueen3032 3 жыл бұрын
He came 3rd in weekly today's weekly contest 202. I don't understand how he did 3 questions in 3mins (easy, medium, medium) and 1 question in 6mins (hard) so total 9mins, and the ones who came 1st and 2nd did all 4 in 7 mins. How come people manage to read, think, code 4 questions including hard questions in just 7-9mins.
@pleasesirmorevideos4684
@pleasesirmorevideos4684 3 жыл бұрын
@@kueen3032 it is all about practice the first two questions are extremely simple and the third one is simple binary search well known question.
@kishorprasad3817
@kishorprasad3817 3 жыл бұрын
@@kueen3032 you can check his videos to realise abt speed, they have immense practice and are active on all coding platforms. Leetcode questions are comparatively easy as compared to codeforces..
@teeksGG
@teeksGG 3 жыл бұрын
I'm almost more impressed by how confident and quick you are on the keyboard. Someone can be just as smart as you but that ability to quickly input everything has to be a major advantage.
@harsh6390
@harsh6390 3 жыл бұрын
bro you are an inspiration to me..the moment i submitted my first solution you had won the contest...
@de_vamp
@de_vamp 3 жыл бұрын
And me at that time, was trying to even understand the problem
@nizz4m
@nizz4m 3 жыл бұрын
@@de_vamp And me at that time, still searching at stackoverflow
@Cuberates
@Cuberates 3 жыл бұрын
and me at that time, wondering if I'm in the right competition
@anmolsharma9539
@anmolsharma9539 3 жыл бұрын
And me at time , thinking which is right language java or cpp
@akshanshthakur9235
@akshanshthakur9235 2 жыл бұрын
And at that time, was born
@GoldenLion5648
@GoldenLion5648 3 жыл бұрын
Great job William! Have you heard of the advent of code? It is a series of coding problems with a story. There is a new problem with two parts released every day in December until Christmas. The old problems are still up if you want to try them/ make videos on them. Keep up the good work!
@harshaaravala2861
@harshaaravala2861 Жыл бұрын
I'm new to programming so I don't understand what he's doing at all but it's fun watching someone solve the hardest of questions with ease.
@omarabozein7015
@omarabozein7015 3 жыл бұрын
Finallyyyyy a new viddd ! Legend thanks for sharing ur knowledge
@tylerxiao2656
@tylerxiao2656 3 жыл бұрын
I am proud to be part of the William Lin Fan Club on Codeforces.
@bohuazhang9145
@bohuazhang9145 3 жыл бұрын
Congrats!
@shariqshaikh5715
@shariqshaikh5715 3 жыл бұрын
william lin can you please suggest us where should we practice more like we can become like you and make our problem-solving skills better?
@yihanlei9220
@yihanlei9220 3 жыл бұрын
i waited for your video for a long time
@Chiby5570
@Chiby5570 3 жыл бұрын
William : Winning the Contest Also William : I don't think I did that well!
@xappppp
@xappppp 2 жыл бұрын
I like this hardcore problem solving video, it could be more revealing than a prepared class.
@pramodmehta8399
@pramodmehta8399 3 жыл бұрын
Heyy william, i was on problem 2 when I saw that you have won the contest. I felt so happy at the moment that you have won. KEEP IT UP ....
@cwagnello
@cwagnello 3 жыл бұрын
William: I didn't do that well ... solves all 4 problems in 10 minutes. Everyone: o_O
@turuus5215
@turuus5215 3 жыл бұрын
Asian culture
@chocho563
@chocho563 3 жыл бұрын
rank 1: i didnt do that well
@mansi3042
@mansi3042 2 жыл бұрын
What else he wants 😐 I won't be able to solve a single problem in that time 😂
@SergeDuka
@SergeDuka 3 жыл бұрын
So basically, the code doesn't have to be efficient, the timing of submission is all that matters, right? I registered on Leetcode like a week ago and they sent me an invitation to this thing, so I'm trying to figure out what it's about. Also, I presume that Python (or C++ for that matter) would win over Java because the code is more concise hence less typing, right?
@user-pj3fs9yo1s
@user-pj3fs9yo1s 3 жыл бұрын
I just finished the first problem when your solutions of all the problems were accepted😫😫😫
@TBasianeyes
@TBasianeyes 3 жыл бұрын
you are still doing better than 95% of us
@folyplays-getgamified3613
@folyplays-getgamified3613 3 жыл бұрын
@@TBasianeyes okay sorry to disturb but what exactly is this? Is this supposed for a certain age group or free for all? And what languages does it support?
@bmxguy418
@bmxguy418 3 жыл бұрын
@@folyplays-getgamified3613 this is a contest on a website for problem solving training for people in the CS industry. You should learn algorithms, data structures and complexity analysis before diving into it. It supports all mainstream languages
@turuus5215
@turuus5215 3 жыл бұрын
bmx guy How can I join this competition?
@folyplays-getgamified3613
@folyplays-getgamified3613 3 жыл бұрын
@@bmxguy418 Thanks! Appreciate it man!
@manas_singh
@manas_singh 3 жыл бұрын
This is the kind of content I like waking up to
@ClashwithAshishClashboy
@ClashwithAshishClashboy 3 жыл бұрын
From where i start to learn advance topics like tree problems or graphs problems based on bfs or dfs........as i m not able to solve these type of problems in contests....kindly guide me
@memesmacha61
@memesmacha61 3 жыл бұрын
Can you please make competitive programming series
@deepraval3406
@deepraval3406 3 жыл бұрын
Make a speedrun video on codechef past long challenges
@vedanshbhardwaj6548
@vedanshbhardwaj6548 2 жыл бұрын
Just imagining how long would your interview last !
@owenizedd2830
@owenizedd2830 2 жыл бұрын
Damn the minimum number of non overlapping solution is really great.
@gokul8747
@gokul8747 3 жыл бұрын
can you make a prep guide on ioi
@pradeepkargwal511
@pradeepkargwal511 3 жыл бұрын
Just think ,how calculations are going on in his mind
@minakshikudalkar557
@minakshikudalkar557 3 жыл бұрын
I submitted my first solution at 10 mins, and you won the contest by then!! Congratulations :)
@grandparick3176
@grandparick3176 3 жыл бұрын
For the love of God someone please tell me what keyboard he uses. Thank you.
@rexgamingcsgoandmore4833
@rexgamingcsgoandmore4833 3 жыл бұрын
Hey william, you better upload a video on you winning Codeforces Round #663 (Div. 2), congrats !!
@rohanpandey9957
@rohanpandey9957 3 жыл бұрын
william lin bro which keyboard do use??
@wthxrsh
@wthxrsh 3 жыл бұрын
How he learnt programming I want to know that..?
@giabao6462
@giabao6462 Жыл бұрын
i admire you so much
@yessirski7868
@yessirski7868 Жыл бұрын
How in the world does anyone get to this point? I would love to be able to go through problems like this.
@cwagnello
@cwagnello 3 жыл бұрын
How can you concentrate with the vacuum cleaner in the background??
@anmolsharma9539
@anmolsharma9539 3 жыл бұрын
🤣🤣
@sailaminoak
@sailaminoak 3 жыл бұрын
Can you explain the last problem
@sorinica
@sorinica Жыл бұрын
hi! I saw you are using vim. Can you give me some links for configuring vim for windows? thanks
@abhigyanshrivastava1255
@abhigyanshrivastava1255 3 жыл бұрын
4:22 why I never had to cast string.size() to 'int', but William is getting a Runtime error?
@samwisegamgee8502
@samwisegamgee8502 3 жыл бұрын
size() returns unsigned int. So when size() is zero, size() - 1 becomes UINT_MAX instead of -1. It's one of the most annoying things.
@Xp-Sam
@Xp-Sam 3 жыл бұрын
can anyone explain why he needed to typecast to int in question 1?
@AlexCarter881
@AlexCarter881 3 жыл бұрын
Make Strings Great Again
@SergeDuka
@SergeDuka 3 жыл бұрын
Yeah, I had the same thought. 😂😂😂
@labgeek1559
@labgeek1559 3 жыл бұрын
is someone vacuuming or just the video? :)
@securityintech
@securityintech 3 жыл бұрын
Why weren't you in Codejam finals?
@cogitoergosum7945
@cogitoergosum7945 3 жыл бұрын
He's not at that level yet. He is still young and have a lot more to learn. If MIT does not take too much of his time this year, he will definitely be in the finals next year. btw He came 138 this year. It's quite a good achievement.
@deepanshuyadav4418
@deepanshuyadav4418 3 жыл бұрын
why s.size() in the first question was needed to be typecasted to int ? Shouldn't size already return int value ?
@guzzo9000
@guzzo9000 3 жыл бұрын
I think it is some weird data type, like std::size_type. Either that, or it's an unsigned int, or something. Idk for sure doe.
@miteshkumar5557
@miteshkumar5557 3 жыл бұрын
You need to typecast it to (signed int) so that if the string is empty, it won't underflow to INT_MAX. s.size() returns an unsigned int dawg.
@vanshjoishar9218
@vanshjoishar9218 3 жыл бұрын
oh my god you look so sleepy dayum! Still manage to win? WTH am i doing with my life?
@samlawson7718
@samlawson7718 3 жыл бұрын
How u do that soo fast
@yujianzhao6461
@yujianzhao6461 3 жыл бұрын
I think for your solution to the first problem, in the worst case like 'abcdeEDCBA', you have to loop N times, which makes your algorithm O(N^2). I think it's easy to do it with O(N). Also, you don't have to use t as a backup of s.
@user-pj3fs9yo1s
@user-pj3fs9yo1s 3 жыл бұрын
I used the stack to do the solution with O(N), but only the largest length of the string is 100, so you can just loop to maximize the time you spend at other problems even though it is an algorithm with O(n^2)
@Arunnn241
@Arunnn241 3 жыл бұрын
Yeah there's definitely better ways, but in a competition with inputs that are going to be low in size, the fastest solution becomes the one you can type out the fastest.
@shahidtauheed7553
@shahidtauheed7553 3 жыл бұрын
Hey bro how r u ?
@springli7917
@springli7917 3 жыл бұрын
so cool
@anilkumarpelluri3795
@anilkumarpelluri3795 3 жыл бұрын
Hey! What's ur goal?
@kaushik.aryan04
@kaushik.aryan04 Жыл бұрын
This guy solved this question in 4 minutes it took me 2 days to solve this (last one)
@intellagent7622
@intellagent7622 3 жыл бұрын
I just got this problem on Roblox OA yesterday LOL
@10minutesandunder
@10minutesandunder 9 ай бұрын
how would he stack up vs tourist
@user-yw7oh3ow7g
@user-yw7oh3ow7g 3 жыл бұрын
William Make A Journey Video about your coding skills.....
@NotFound-hy7qb
@NotFound-hy7qb 3 жыл бұрын
One request - You should post your solutions in discussion section of leetcode that would help alot
@chishikiendeavourer8663
@chishikiendeavourer8663 8 ай бұрын
His solving ability is relevant to George Hortz😮
@vamp7435
@vamp7435 3 жыл бұрын
Hey William! I was wondering how you inverted the integers in the second question. Also, what does c^=1 do, and does it invert c?
@cbyitina4170
@cbyitina4170 3 жыл бұрын
^ means XOR, x ^ y -> return x == y ? 0 : 1;
@Piyush-yp2po
@Piyush-yp2po 10 ай бұрын
It is xor operation, 1^1=0 and 0^1=1 , so it basically inverts
@sihoonoh9021
@sihoonoh9021 Жыл бұрын
I don't know much about coding, so please correct me if I am wrong. For the cutting problem, can't you be more greedy with it? You compare each pair of partitions parted by the cuts, and the smallest pair gets cut last.And assuming the cut in this partition is now patched , repeat the same process and you get the second to last cut... and so on in this way you work backwards. I don't understand C code, but I am guessing from the fact you said dynamic programming ,the complexity is factorial, if you consider every single cut, and every single cut excluding the previous cut, and so on. Mine can be done in n+(n-1)+(n-2)+ =n^2, what is wrong with this?
@mfjww
@mfjww 5 ай бұрын
Greedy is not correct, you have to consider every combination. And the time complexity of dynamic programming in the video is n^3
@zoravier7549
@zoravier7549 3 жыл бұрын
what for(int i=cuts.size() ; ~i; --i) what is ~i operrator can anyone explain.
@AustinHong-re1ij
@AustinHong-re1ij 8 ай бұрын
It’s the bitwise not operator. When i becomes -1 it’s bit representation is set to all one and biteise not operator will turn it into 0 at which point the for loop terminates
@tydical
@tydical 3 жыл бұрын
It feels like when he is typing the video is at 2x and when speaking it's at 1x. When di youtube start tis feature?
@fuadf.7842
@fuadf.7842 3 жыл бұрын
idk what is he doing but i still watch it till end tho
@amiteshsingh4165
@amiteshsingh4165 3 жыл бұрын
OP
@kumarshivam8077
@kumarshivam8077 3 жыл бұрын
How many years have you invested on programming
@snggaming6088
@snggaming6088 3 жыл бұрын
10years
@bunnyhop9798
@bunnyhop9798 3 жыл бұрын
How to study for competitiv programming?
@renaldiatma7828
@renaldiatma7828 3 жыл бұрын
@@cogitoergosum7945 thank you....
@trexbattle
@trexbattle 3 жыл бұрын
Algo expert io ad but tht lisp dudes girl lookin veluctuous
@prakash_77
@prakash_77 3 жыл бұрын
Did you mean voluptuous?
@marcosamuel17
@marcosamuel17 3 жыл бұрын
Hello!
@WilliamYFeng
@WilliamYFeng 3 жыл бұрын
Haha, problem 4 almost got me. I implemented a DP table in the last 2 minutes and it worked :D Reaction: kzfaq.info/get/bejne/ZtakpcuBzs_SgKs.html
@anmolsaxena6630
@anmolsaxena6630 3 жыл бұрын
Who are here after Love babbar video?
@perfectgamer9208
@perfectgamer9208 3 жыл бұрын
Change colour of chrome
@srishtikdutta8946
@srishtikdutta8946 3 жыл бұрын
Next Video -->Codechef long in 12 hours.
@cogitoergosum7945
@cogitoergosum7945 3 жыл бұрын
Gennady is a beast!! It's time for him to retire now and change the world with his mind.
@brandish-so1rq
@brandish-so1rq Жыл бұрын
просто пришел и затащил игру
@pleasesirmorevideos4684
@pleasesirmorevideos4684 3 жыл бұрын
can't you discuss the solutions also? otherwise there is no point in watching this
@snipersquanza1453
@snipersquanza1453 3 жыл бұрын
He sometimes posts explanations to these types of problems, however he just posts these to show his coding process, but not in-depth because he needs to go quick.
@irdunno2204
@irdunno2204 3 жыл бұрын
It's a contest, I don't think he would waste time explaining when the time is ticking.
@pleasesirmorevideos4684
@pleasesirmorevideos4684 3 жыл бұрын
@@irdunno2204 i am talking about adding explainations after the contest ends.
@HDbIce-oj3wv
@HDbIce-oj3wv 3 жыл бұрын
@@pleasesirmorevideos4684 I agree with you
@kevinrojas7665
@kevinrojas7665 3 жыл бұрын
The best you can do is try this you own and when you've solved them or have a nice grasp of what happened see the videos. That way you'll now what's happening and understand his solutions
@Warrior97489
@Warrior97489 3 жыл бұрын
Why you upload only when you win? Pls upload regardless so that we can watch and learn. Thanks.
@HiPh0Plover1
@HiPh0Plover1 3 жыл бұрын
u better fucking win google code jam next year , i mean tourist been winning for 7 years wtf
@VrickzGamer
@VrickzGamer 3 жыл бұрын
please solve codechef AUGUST LONG CHALLENGE BROO
@knowledgepoint2124
@knowledgepoint2124 3 жыл бұрын
Hey william, i have a question for you, How much had you scored in your 10th standard???
@HAL--vf6cg
@HAL--vf6cg 3 жыл бұрын
what an idiot
@udhavvarma7097
@udhavvarma7097 2 жыл бұрын
How is it relevant?
@fanaticalplel1003
@fanaticalplel1003 3 жыл бұрын
This guy definitely has google and ibm and a whole lot of companies begging for him to work there
@user-gz6bg3kr2l
@user-gz6bg3kr2l 3 жыл бұрын
兄弟你是怎么练习的呀,我也练习,但是和你的速度比起来差很多,有什么方法么?
@Felven
@Felven 3 жыл бұрын
O.O
@svsrkpraveen
@svsrkpraveen 3 жыл бұрын
I could only solve 2 problems in 1.5 hours :(
@mozammil4380
@mozammil4380 3 жыл бұрын
kindly try to add a keyboard cam it will be great to watch you type at that speed..... beginners like my want to learn your style
@seqi1890
@seqi1890 3 жыл бұрын
orz
@cbyitina4170
@cbyitina4170 3 жыл бұрын
I doubt he was already able to code when he was born.
@mc-nf7hd
@mc-nf7hd 3 жыл бұрын
8th
@shubhmishra66
@shubhmishra66 3 жыл бұрын
No views 3rd like
@danielchoi6128
@danielchoi6128 3 жыл бұрын
First
@tmwilliamlin168
@tmwilliamlin168 3 жыл бұрын
Congrats!
@shashikantkumar5095
@shashikantkumar5095 3 жыл бұрын
@@tmwilliamlin168 lol
@jhashivam28
@jhashivam28 3 жыл бұрын
William 1 request plz plz plz plz Make atleast 1 vdo doing CP in java plz 🙏
@user-od7vs2fs2v
@user-od7vs2fs2v 7 ай бұрын
he is just insane 🫥🫥man
@kunalaggarwal3867
@kunalaggarwal3867 2 жыл бұрын
It took me 50 mins to come up with an approach and solve the last question and this guy solved that question within 3 minutes and still complained that he didn't do well in the contest.🥲
@pearlinperil9985
@pearlinperil9985 2 ай бұрын
50mins is still good dw
@seqi1890
@seqi1890 3 жыл бұрын
orz
LeetCode Biweekly Contest 30 (2nd)
12:50
William Lin
Рет қаралды 52 М.
Winning LeetCode Weekly Contest 198
40:27
William Lin
Рет қаралды 109 М.
Универ. 13 лет спустя - ВСЕ СЕРИИ ПОДРЯД
9:07:11
Комедии 2023
Рет қаралды 6 МЛН
Sigma Girl Past #funny #sigma #viral
00:20
CRAZY GREAPA
Рет қаралды 23 МЛН
Final muy inesperado 🥹
00:48
Juan De Dios Pantoja
Рет қаралды 19 МЛН
Training for GOLD for US at International Olympiad in Informatics
3:45
I Solved 1583 Leetcode Questions  Here's What I Learned
20:37
ThePrimeTime
Рет қаралды 542 М.
Winning Codeforces Round #663 (Div. 2)
46:18
William Lin
Рет қаралды 95 М.
How I would learn Leetcode if I could start over
18:03
NeetCodeIO
Рет қаралды 271 М.
The unfair way I got good at Leetcode
6:47
Dave Burji
Рет қаралды 384 М.
Starting Competitive Programming - Steps and Mistakes
9:55
William Lin
Рет қаралды 1,4 МЛН
Google Kickstart Round B 2020
1:37:36
William Lin
Рет қаралды 149 М.
Yes, I was also Bad at LeetCode
3:20
NeetCodeIO
Рет қаралды 114 М.
Leetcode Weekly Contest 402 | Video Solutions - A to D | by Abhinav Kumar | TLE Eliminators
55:27
Almost Winning Google Kickstart Round E 2020
47:37
William Lin
Рет қаралды 180 М.
😨 Это реально Самый Высокий миф в Майнкрафт
37:29