Maximum sub-array is a programming challenge on LeetCode. You are provided with an array of integers. These elements could be all positive, all negative or a combination of both. A sub-array is a smaller array formed using the elements of the original array. The condition for this problem is that the elements of the sub-array should be contiguous. Out of all the contiguous sub-arrays possible we need to find the maximum sum that can be formed. Watch the video to understand the problem in a simplified manner. I then work along with you to solve it first using a Brute Force approach, and then an efficient approach. All along with visuals and explanations.
00:00 - Intro
00:29 - Problem Statement and Test Case
02:15 - Brute Force Method
04:15 - Optimized Solution
07:10 - Dry-run of code
📚 Links I talk about in the video:
Actual problem on LeetCode: [ Ссылка ]
Code on Github: [ Ссылка ]
Test cases on GitHub: [ Ссылка ]
📘 A text based explanation is available at: [ Ссылка ]
Kadane's algorithm: [ Ссылка ]
To see more videos like this, you can show your support on [ Ссылка ]
💻 Get Social 💻
Follow on Facebook at: [ Ссылка ]
Follow on Twitter at: [ Ссылка ]
Follow on Tumblr at: [ Ссылка ]
Subscribe to RSS feeds: [ Ссылка ]
#leetcode #programming #interview
Ещё видео!