in Programming recategorized by
105 views
0 votes
0 votes
Consider the following Python code:

S[1] = [1]
x = [6, 3, 5, 4, 10]
for i in range(2, len(x)):
    S[i] = [1]
    if x[i - 1] <= x[i]:<br />        S[i] = S[i] + S[i - 1]

Output of the code.
in Programming recategorized by
105 views

Please log in or register to answer this question.