Build A Min Height BST From A Sorted Array | Coding Interview Question

preview_player
Показать описание
Back with another video and a special offer on our lifetime membership for you - use the promo code: APRIL40 to get 40% off on our subscription 🎉

📹 Intuitive Video Explanations
🏃 Run Code As You Learn
💾 Save Progress
❓ New Unseen Questions

Given a sorted array, create a binary search tree with minimal height.

Input:
[1, 2, 3, 4, 5, 6, 7]

Output:
[4, 2, 6, 1, 3, 5, 7]

Explanation:
4
/ \
2 6
/ \ / \
1 3 5 7
Рекомендации по теме
Комментарии
Автор

And when the world needed him the most, he returned.

SheikhAsif
Автор

That feeling when saw the notification from Back to Back SWE.

siddharthshankarpaul
Автор

Thankyou so much! Every time I prepare for the interviews, I come back to your videos, keep going, you are making a huge difference in the world of teaching DSA :)

reemasharma
Автор

Missed your content bro. Glad you are back 😊

interested_in_everything
Автор

your videos have been really helpful for my studies at university! please keep going. it's really nice to see you posting again :)

asal
Автор

Thanks for video! It's great to see you again!!!

hanaksi
Автор

fk twitter, youtube is your home, the place where you get the most respect 💯💯💯💯

iamdaddy
Автор

I started watching your videos a few days ago and have found your content to be amazing, I left a query on your website asking if there's a trial period for potential members etc. - anyways the website isn't working for me anymore (bad certificate error) and no replies so far :(. Best of luck on your venture though and I hope there's some discounts and some short mini courses available in May

SaljooqAltaf
Автор

no way this dude came back from the dead exactly when i started watching his channel

energy-tunes
Автор

Such quality video from a channel but so little videos to watch. Lol comeback man.

pet.me
Автор

What is your chest workout routine bro pump is insane :)

goktugparlak
Автор

Hi! New to the channel and content, but I am wondering what your plan for content is in the future

Prefer
Автор

hey. I am a year late. Though my question is, do we set the right index to array.length or array.length-1 and what would that do to the algorithm. If someone can help me with that, it'd be great. love this channel.

uroobaazhar
Автор

Can you please do a video on loop invariants to prove correctness?

MadMax-pkss
Автор

Hey, your site is not available, ssl cert is invalid

MrOliwander
Автор

The platform is down for couple days😢

Keep showing “the origin web server does not have a valid SSL certificate” error message 😫

nnnuchn
Автор

Hey, we miss you! You are busy we get it, but try to make new videos 😅👏🏼👏🏼👏🏼

bakhtiyardoskenov
Автор

you bastard, don't dare you go away again

angeldarco
Автор

I would prefer nums.length - 1 as it's more intuitive and the left = line should end at mid - 1

rydmerlin