Тёмный

Codeforces Round  

William Lin
Подписаться 399 тыс.
Просмотров 59 тыс.
50% 1

Опубликовано:

 

26 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 168   
@othmanebentaleb
@othmanebentaleb 4 года назад
For the last problem, there is a permutation that is always valid: print odd numbers in a descendant order, then print the even numbers in ascendant order (swap 2 and 4 to match the diff condition)
@yesil1026
@yesil1026 4 года назад
Yes, that is the first thing I also considered. For odd n: 1, 3, 5, 7, ..., n, n - 3, n - 1, n - 5, n - 7, n - 9 ... is a valid sequence. For even n: 1, 3, 5, 7, ..., n-1, n - 4, n, n - 2, n - 6, n - 8, n - 10 .... is a valid sequence.
@bsethupathi1
@bsethupathi1 4 года назад
This is a Div 4 contest targeting the unrated coders. He is too OP for this round.
@huskydj1
@huskydj1 4 года назад
He was participating unofficially...
@1010ansh
@1010ansh 4 года назад
Thank you for providing such a good explanation and implementation for this problem.
@ultra_mega_tronic_source
@ultra_mega_tronic_source 4 года назад
I don't know what's happening...
@parthshah8057
@parthshah8057 4 года назад
Ended up 4th, since it was a Divison 4 contest. Will end up 3rd, since it will be a Divison 3 contest. Will end up 2nd, since it will be a Divison 2 contest. Will end up 1st, since it will be a Divison 1 contest.
@clipit4503
@clipit4503 4 года назад
😂😂😱
@User-ip9dg
@User-ip9dg 4 года назад
Being number 1 is tough when tourist is in a contest.
@abuhuraira071
@abuhuraira071 4 года назад
@@User-ip9dg MifafaOvo also
@shashanksabharwal8591
@shashanksabharwal8591 4 года назад
*hey* may be *you* guys are good coders ... Please help me guys .. I have only 1 year to learn programiing and build some good skills so i will get a good job... I am learning C language still please reply anyone.. What to do after C .. For getting place ld in companies like amazon, paytm
@sauravkarmakar3704
@sauravkarmakar3704 4 года назад
@@shashanksabharwal8591 language doesnt matter , the algorithms u learn and their implementations matter
@rohitpal7739
@rohitpal7739 4 года назад
I did 4 took me 2 hrs almost did 5 and was happy until... Lot to learn
@clipit4503
@clipit4503 4 года назад
You can do it! You will get there practice makes better!
@ritamr2690
@ritamr2690 4 года назад
i didn't get any... i started on c bc it looked so easy but i got tle and then just rage quit lol
@rohitpal7739
@rohitpal7739 4 года назад
@@ritamr2690 keep trying and be consistent that's what I am trying currently
@rohitpal7739
@rohitpal7739 4 года назад
@@clipit4503 Thanks
@shashanksabharwal8591
@shashanksabharwal8591 4 года назад
@@rohitpal7739 hey may be you guys are good coders ... Please help me guys .. I have only 1 year to learn programiing and build some good skills so i will get a good job... I am learning C language still please reply anyone.. What to do after C .. For getting place ld in companies like amazon, paytm
@JayPatel-jn7cu
@JayPatel-jn7cu 4 года назад
3rd problem can be seen as - ans = ans/n + k , find the ans ans =floor(( n*k -1)/(n-1))
@tanmaymishra9203
@tanmaymishra9203 4 года назад
Lol..I found formula (k-1)//(n-1) + k.. dunno how it arrived
@jayantjha3128
@jayantjha3128 4 года назад
Thats wrong actually. Try n=7 and k=97. Answer shld be 113
@jayantjha3128
@jayantjha3128 4 года назад
I also thought of the same
@utsavsingh899
@utsavsingh899 4 года назад
As always the timing is awesome... just after contest (perfect time to upsolve)
@shashanksabharwal8591
@shashanksabharwal8591 4 года назад
Rohit Pal hey may be you guys are good coders ... Please help me guys .. I have only 1 year to learn programiing and build some good skills so i will get a good job... I am learning C language still please reply anyone.. What to do after C .. For getting place ld in companies like amazon, paytm
@ATGG
@ATGG 4 года назад
Literally, every time I see your videos, my mouth stays Wide Open
@yesil1026
@yesil1026 4 года назад
K'th not divisible by n can be calculated analytically. Its k + floor((k - 1)/(n-1))
@EintsWaveX
@EintsWaveX 3 года назад
Omg dude, i never think such of this solution... Impressive
@boomboom-9451
@boomboom-9451 2 года назад
why k-1 part
@0xero7
@0xero7 4 года назад
I found another elegant(imo) solution for G, first it is obvious for n < 4 it's impossible for n = 4 you can have 3 1 4 2 now, for every increasing n, add odd numbers to the left and even numbers to the right. for example if n = 7, add 7 and 5 to the left of 3 1 4 2, and 6 to the right. 7 5 3 1 4 2 6 and so on :)
@srinivast84
@srinivast84 4 года назад
Cool
@anoubhav
@anoubhav 4 года назад
Really cool
@debadiptobiswas5611
@debadiptobiswas5611 4 года назад
i did the same
@youarecorrectiamwrongbecau1338
@youarecorrectiamwrongbecau1338 4 года назад
Oh it's amazing.
@thallium54
@thallium54 4 года назад
same solution
@sterlingmaloryarcher747
@sterlingmaloryarcher747 4 года назад
Lin: Makes video so that people learn about CP Me: What are your VIM settings?
@ianpan0102
@ianpan0102 4 года назад
syntax on set nu set ai ... Pretty much it
@Sam-nd6np
@Sam-nd6np 4 года назад
I still don’t understand how he did problem 1 so quickly, can anyone explain how? I did it in 16 minutes lol
@18PregnantAndProud
@18PregnantAndProud 4 года назад
Sam Penny maybe he did that same problem before
@rocknroll7967
@rocknroll7967 4 года назад
He is red bro, they can generally solve these type of questions without even picking pen and paper.
@mynewnameisbeautiful___4717
@mynewnameisbeautiful___4717 4 года назад
Its very easy if you are familiar with problems when you need to do somthing with the digits of a number, I solved it in the contest ~1.5 minute
@shashanksabharwal8591
@shashanksabharwal8591 4 года назад
Rohit Pal hey may be you guys are good coders ... Please help me guys .. I have only 1 year to learn programiing and build some good skills so i will get a good job... I am learning C language still please reply anyone.. What to do after C .. For getting place ld in companies like amazon, paytm
@sauravkarmakar3704
@sauravkarmakar3704 4 года назад
@@shashanksabharwal8591 some OOP language, then focus on algorithms and solve interview questions
@dudemysterio
@dudemysterio 4 года назад
Great Vids but William could you make a video with your VIM setup it would be a great video for people. Keep up the good work.
@getsuha
@getsuha 4 года назад
Hi @William Lin Can you please share a video with your VIM settings....
@cartist3019
@cartist3019 3 года назад
You're ultra Pro in competitive programming William
@almaaune3596
@almaaune3596 4 года назад
Hi William! I really enjoy your videos! Could you perhaps do another post on how you improve your programming skills. I would like to get better with coding logic but I am hitting some walls, for example coding logic of hackerrank's easy to medium section. Is there reference material that you read to get better?
@justaguyonyt869
@justaguyonyt869 2 года назад
He’s Asian
@rajdave9862
@rajdave9862 4 года назад
Hey, I literally took 4 minutes to understand 2'nd problem (B) but you solved it in less than 3 minutes How how how? Please tell us How are you able to think this much faster, Do you have old experience of these problems or you came across these problems first time
@rajdave9862
@rajdave9862 4 года назад
@@bulletprooftrading that's sounds great, thanks Sasmit Vaidya
@yz767
@yz767 4 года назад
Good job and thanks for explanations :D
@partth-p9t
@partth-p9t 4 года назад
Can you please make a video on how to setup Vim. I watched your CP video and it has inspired me to code too. 😊🙏
@kuljeetsinghvirk1299
@kuljeetsinghvirk1299 4 года назад
love your content man. keep it up..
@kuljeetsinghvirk1299
@kuljeetsinghvirk1299 4 года назад
I was also thinking to participate in this contest but I think I did right by not participating
@sauravkarmakar3704
@sauravkarmakar3704 4 года назад
@@kuljeetsinghvirk1299 why
@kuljeetsinghvirk1299
@kuljeetsinghvirk1299 4 года назад
@@sauravkarmakar3704 kidding bruh!!! I was just admiring his skills.
@aw12sdfx
@aw12sdfx 4 года назад
my new favourite asmr
@tilakmadichettitheappdeveloper
@tilakmadichettitheappdeveloper 3 года назад
i can imagine 4 years from now div 1 in 20 minutes.
@Zildras
@Zildras 2 года назад
what keyboard uses in this video?
@badeeesmandar2552
@badeeesmandar2552 4 года назад
1st problem took me an hour😂😂 I'm soo noob😭
@jethalalnhk2409
@jethalalnhk2409 4 года назад
I could not solve second
@AdityaSharma-ei4gq
@AdityaSharma-ei4gq 4 года назад
You guys are solving problem?
@debadiptobiswas5611
@debadiptobiswas5611 4 года назад
For C: answer is ceil(n*k/(n-1)) - 1
@kaiovieira230
@kaiovieira230 4 года назад
Simpler than mine =D
@CharlesMacKay88
@CharlesMacKay88 4 года назад
ceil(n*k/(n-1)) - 1. good find.
@debadiptobiswas5611
@debadiptobiswas5611 4 года назад
@@CharlesMacKay88 Yeah there's a -1, thanks for pointing out
@karthiksk7246
@karthiksk7246 4 года назад
I did the same!!
@sriharshaananthoju8671
@sriharshaananthoju8671 4 года назад
Will rating changes be so minimal in this division because only greens and greys
@karanpatel7974
@karanpatel7974 4 года назад
Great video William, do you have any advice to learn c++ as a beginner, I know java (programming) but I am trying to learn c++, any advice would be really helpful.
@youarecorrectiamwrongbecau1338
@youarecorrectiamwrongbecau1338 4 года назад
I was really scared from c++. Just couldn't switch from python. Now I find cpp better in many situations. I would give you an honest advice. Mostly people will say read this read that. I'll say, just learn 3 - 4 important operations of all stl data structures by googling their name like map set vector etc. Almost everything in cp is done using those 90% of the time.
@gameplayvideos3113
@gameplayvideos3113 4 года назад
C++ is way easier than Java and python is the easiest
@mynewnameisbeautiful___4717
@mynewnameisbeautiful___4717 4 года назад
I think this round was has the worst problms for beginers
@sauravkarmakar3704
@sauravkarmakar3704 4 года назад
yes i completely demotivated me
@happyhappyguy5034
@happyhappyguy5034 4 года назад
why?
@tanmaymishra9203
@tanmaymishra9203 4 года назад
Do u mean the problems were more easy or more difficult?
@HarshSharma-je8rk
@HarshSharma-je8rk 4 года назад
Is there any discord server created by William lin... Pls send the link
@bensontoh92
@bensontoh92 4 года назад
check the description....
@shashanksabharwal8591
@shashanksabharwal8591 4 года назад
hey may be you guys are good coders ... Please help me guys .. I have only 1 year to learn programiing and build some good skills so i will get a good job... I am learning C language still please reply anyone.. What to do after C .. For getting place ld in companies like amazon, paytm
@aryamitabh
@aryamitabh 4 года назад
For G, you can just go 2 4 6 8 ... then go back in reverse for the odds but by changing a couple of things. Like for n = 10, you can do 2 4 6 8 10 7 9 5 3 1. Just a change in the order of 7 and 9. Another method can be placing the elements in 4 groups based on their value mod 4. Then printing all 0 mod 4 in ascending order, then 1 mod 4 in descending order, then 2 mod 4 in ascending and 3 mod 4 in descending.
@rashidmazhar023
@rashidmazhar023 4 года назад
How do you have this themed chrome?
@JoaoVictor-lq5ew
@JoaoVictor-lq5ew 4 года назад
Awesome, I like so much your videos, thanks for all
@forhanshahriarfahim9493
@forhanshahriarfahim9493 4 года назад
@William Lin How you load all problem in one page ??
@mostafamohamed2
@mostafamohamed2 4 года назад
When you open normal problems page you can see "Complete Problemset" just click it.
@aliabbasattarwala9130
@aliabbasattarwala9130 4 года назад
Which editor u use ?
@srinivast84
@srinivast84 4 года назад
It's Vim (Visual IMproved).
@tanujnamdeo
@tanujnamdeo 4 года назад
Why does he use comma with cin? Can anybody explain?
@ManishKumar-jj1nt
@ManishKumar-jj1nt 4 года назад
If your talking about cin.tie? If yes then it is used for fast I/O in c++. Just google about them to know more or ping me.
@happyhappyguy5034
@happyhappyguy5034 4 года назад
@@ManishKumar-jj1nt No
@happyhappyguy5034
@happyhappyguy5034 4 года назад
Comma is just for separating statements
@happyhappyguy5034
@happyhappyguy5034 4 года назад
And also with comma, you do not have to add the curly braces to contain two statements
@tanujnamdeo
@tanujnamdeo 4 года назад
@@happyhappyguy5034 Thanks
@entertainshala
@entertainshala 4 года назад
How did you learn all these
@goldy7243
@goldy7243 4 года назад
Superhuman speed
@almuhimen8023
@almuhimen8023 4 года назад
For problem C I was sure I will get a TLE. That's why ai tried figuring out a formula. So, my time complexity was O(1).
@andrewalbrekht9399
@andrewalbrekht9399 4 года назад
which formula you used? I also got a TLE , but i couldnt firuge out a formula
@ritamr2690
@ritamr2690 4 года назад
@@andrewalbrekht9399 me too i basically did brute force
@vamsikrishnavalluru611
@vamsikrishnavalluru611 4 года назад
Damn the screenshot is good but why do we need the head on the top corner :/
@priyanksatasiya1366
@priyanksatasiya1366 4 года назад
best part is 28:25 is there anything else? okay ya nothing else😂
@pk4780
@pk4780 4 года назад
you should stream on twitch
@abhiraj9990
@abhiraj9990 4 года назад
4 or 5th Ps:i know ur alts 😂😂😂
@abdoulayebah215
@abdoulayebah215 4 года назад
Hello everyone! Can you tell me please which language is he using ?
@srinivast84
@srinivast84 4 года назад
It's c++.
@kairatopa9564
@kairatopa9564 4 года назад
Z++
@gameplayvideos3113
@gameplayvideos3113 4 года назад
10++
@vinaysinghjadon1959
@vinaysinghjadon1959 4 года назад
This guy is hacking !!!!!
@shashanksabharwal8591
@shashanksabharwal8591 4 года назад
hey may be you guys are good coders ... Please help me guys .. I have only 1 year to learn programiing and build some good skills so i will get a good job... I am learning C language still please reply anyone.. What to do after C .. For getting place ld in companies like amazon, paytm
@jewishfloppa6969
@jewishfloppa6969 4 года назад
He types too fast X_X
@khaledjubeh8818
@khaledjubeh8818 4 года назад
screencast for the next Div1 round.. its will be more interesting
@SamDaBest
@SamDaBest 4 года назад
I only did 4 problems :( I’m so bad
@ezalor9555
@ezalor9555 4 года назад
Well I did 0 so you're better than me, cheer up!
@andrewalbrekht9399
@andrewalbrekht9399 4 года назад
i did only 1 problem :(
@pluviophile762
@pluviophile762 4 года назад
I also did only one
@roloskan9671
@roloskan9671 4 года назад
c:
@pavanvenkat9182
@pavanvenkat9182 4 года назад
Missed your videos
@teji7723
@teji7723 4 года назад
No dislikes :D
@HarshitSharma-cl6io
@HarshitSharma-cl6io 4 года назад
I am in love with your skills I want the same skills pursuing cse
@gameplayvideos3113
@gameplayvideos3113 4 года назад
Since you don't even know the spelling of pursuing/pursue I doubt you will make it that far
@gameplayvideos3113
@gameplayvideos3113 4 года назад
@Samuel Benson 😂😂😂
@HarshitSharma-cl6io
@HarshitSharma-cl6io 4 года назад
@@gameplayvideos3113 have u ever hear abt typos ....or rather say typing errors nevertheless u will say u don't even know the spelling ........lol ...i don't mind u corrected my mistake, in fact, I will prove u wrong by practising and grooming my skills ...have a great life ahead
@gameplayvideos3113
@gameplayvideos3113 4 года назад
@@HarshitSharma-cl6io if you need any help regarding coding/programming reach out to me. I am a developer at IBM
@nishansingh77
@nishansingh77 4 года назад
This guy is too too fast! He is the flash of CP!
@aishikbhattacharya7823
@aishikbhattacharya7823 4 года назад
This is...
@Deepakverma-ox8pd
@Deepakverma-ox8pd 4 года назад
This is wrong why u participated its for under rating 1400 ....this is why beginners cant get good rank.....😅😂😂😂😂 I did 3.....😅
@a.sana04
@a.sana04 4 года назад
I did 0! 😂
@cheissmart
@cheissmart 4 года назад
@@a.sana04 0! = 1 XD
@anmolvarshney5-yeariddindu442
@anmolvarshney5-yeariddindu442 4 года назад
he participated unofficially(doesn't affect rank)😂😂
@TahsinAhmed-yj9ns
@TahsinAhmed-yj9ns 4 года назад
Did A&C stuck on B Any help on B? When should we print no
@ankitthapa9062
@ankitthapa9062 4 года назад
@@TahsinAhmed-yj9ns read the ques carefully.
@teddy911
@teddy911 4 года назад
你中文好不好啊,下回视频说说中文呀
@not_the_dice
@not_the_dice 4 года назад
What is this font in Vim?
@kaiovieira230
@kaiovieira230 4 года назад
In C, here is my method, which I'm proud of: The answer is ((N - 1) / K)*K + (N - 1)*K ( - 1 if (N - 1) % K == 0) Don't ask me why. I hope that intuition method is hack-immune (correct)
@pguerin7095
@pguerin7095 4 года назад
I'll never understand how people just come out with formulas like that during contests lol
@snehasishsamanta1319
@snehasishsamanta1319 4 года назад
I also applied the same formula
@SamDaBest
@SamDaBest 4 года назад
I used the same formula, it won’t be incorrect because it is calculated with math
@daviddafitt
@daviddafitt 4 года назад
O(1) solutions ftw XD
@mashedpotato5694
@mashedpotato5694 4 года назад
I did n*k/(n-1) and -1 if k%n=0
@aser2535
@aser2535 4 года назад
Did you do math competitions before competitive programming? Also, do you know discrete math? If so, would you say that discrete math has helped you, whether directly or indirectly in solving these questions?
@itsvaleska7814
@itsvaleska7814 4 года назад
Aser just incase he reply
@teddychow8487
@teddychow8487 4 года назад
When collab with tzuyu_chou?
@longlin18
@longlin18 4 года назад
I don't understand problem B! Why the output of 100 4 is YES 55 5 5 35 different his result YES 1 1 1 97 but he right?
@zarc5744
@zarc5744 4 года назад
Output For each test case print: YES and the required values ai, *if the answer exists (if there are several answers, print any of them)* For such type of questions its better to not look at the testcases, come up with your own approach that satisfies the question. The testcases are designed in a way to trick you, so you start spending time on how to get output like the test cases and eventually you don't solve the problem
Далее
Winning Google Kickstart Round A 2020 + Facecam
17:10
Avaz Oxun - Turqi sovuq kal
14:50
Просмотров 828 тыс.
+1000 Aura For This Save! 🥵
00:19
Просмотров 2,9 млн
Google Kickstart Round B 2020
1:37:36
Просмотров 150 тыс.
10 years of coding in 13 minutes
13:28
Просмотров 4,9 млн
Programming Competitions (Codeforces, Code Jam, ...)
11:01
I Feel Bad For New Programmers
19:12
Просмотров 449 тыс.
Advice from the Top 1% of Software Engineers
10:21
Просмотров 3,3 млн
Google Coding Interview With A High School Student
57:24
touristream 018: Codeforces Round 769 (Div. 2)
1:57:28
Просмотров 67 тыс.