Horje
programe to find contagious sum of sequence Code Example
programe to find contagious sum of sequence
n = [2,-3,-4,4,-5,6]

sum_list = []

for i in range(len(n)):
    for j in range(len(n)):
        if j<i:
            continue
        else:
            x = sum(n[i:j+1])
            sum_list.append(x)
print(max(sum_list))




Python

Related
getting player input python Code Example getting player input python Code Example
form is undefined flask Code Example form is undefined flask Code Example
What is the purpose of open ( ) and close ( )  in os Code Example What is the purpose of open ( ) and close ( ) in os Code Example
trim all new rows string python Code Example trim all new rows string python Code Example
Random Hex Colors bar generator, python turtle Code Example Random Hex Colors bar generator, python turtle Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
7