Skip to content

damjanprvc/MaximumSubarrayProblem

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MaximumSubarrayProblem

NOTE: This project is aimed towards solving the maximum subarray problem using Dynamic Programming, which is the most efficient way of solving this kind of problem. Time Complexity: O(n)

The maximum subarray problem is the task of finding the contiguous subarray within a one-dimensional array of numbers which has the largest sum.

Solution

Class MaximumSubarrayProblem shows the classical problem. The input Array may contain positive and negative numbers.

Class MaximumSubarrayProblemColor is a slight variation of this problem. The input Array contains colors. Each color has its own value (positive or negative integer).

Releases

No releases published

Packages