Text Justification - Leetcode 68 - Python

preview_player
Показать описание
Solving Leetcode 68, Text Justification. While it's definitely difficult, I don't think it's as bad as you would expect. Though the problem is poorly worded imo.

0:00 - Read the problem
0:30 - Drawing Explanation
6:45 - Coding Explanation

leetcode 68

#neetcode #leetcode #python
Рекомендации по теме
Комментарии
Автор

This question has been the bane of me for years now

flueesyblueesy
Автор

Hey Neet, I love you, man. I wish I could meet you someday. Your videos are greatly organized and so helpful.

Syed_Shifat
Автор

I got this one in a CodeSignal assessment. Solving this PLUS 3 other (smaller) questions in a 70-minute time frame? Forget it.

CST
Автор

I've been waiting for this one from you

RagingAcid
Автор

this is really good, your coding style is very easy to understand !

manasawalaaamir
Автор

They legit asked this exact same question in the coding round for DevRev and I was able to solve it!

garth
Автор

the string section of the 150 problem set was mostly easy, and then at the very end they drop this bombshell.

agrimpuriya
Автор

Thank you so much for the daily problems

MP-nyep
Автор

I was asked this question in a phonescreen for an AI startup today. Absolutely bombed it :(

animesh
Автор

Finally!!! Thank you. Needed this one.

VidyaBhandary
Автор

The Problem was good. It imporves your thinking. Can you share more problem like these? Thanks for the explanation!

aadil
Автор

I solved this but mine is quite long and handles cases separately. This is very neat. On the lines of some top solutions on the Leetcode page, but those solutions are super hard to understand.

hbhavsi
Автор

I mean, if they would have ask me this question in interview, I would have just asked the interviewer to put his hand on his heart and be truthful whether he had done this question by themselves.

vincyDoo
Автор

Had to rewatch once but good explanation.

impatientgaming
Автор

very useful video, thanks for amazing explaination . Can you please tell me where is this mention that there has to be space between 2 consecutive words in the line. Like in example 3 : line#3 has the word enough which can be fir easily in the line#2 if we don't keep space in between two words.Please tell me if I have misinterpreted the question, because I can not find any such restriction in question where it says that there has to be a space in between consecutive words.On the other hand, it clearly mentions that " each line has exactly maxWidth characters ", see question is only talking about characters, no constraints given about compulsary word prefix/suffix . Please help

kidscodera
Автор

saw your video and wrote the code in C++, ACC in 1st attempt

ManishKumar-ztsk
Автор

Thanks for uploading the dailies again!

vinleous
Автор

This was one of the easiest hard questions.

ruthlessogre
Автор

Is the space complexity of this is o(n) where n is the number of words for each line....? please correct me if I'm wrong....

chirpy
Автор

This in itself is a microservice for sure.

theja
visit shbcf.ru