Python 3, 107106 bytes
def f(a,n=-1,x=0):a[n]-=x;return~-any(a)^any(f(a[:]1*a,i,j+1)for i,k in enumerate(a)for j in range(x,k)if i-n)
Brute force search. Recursively subtracts a strictly increasing valuex from every indexi in the inputa, as long as iit is not equal to the lastprviously picked indexn. This continues until all values in athe input are zero or the options to continue are exhausted.
Python 3, 107 bytes
def f(a,n=-1,x=0):a[n]-=x;return~-any(a)^any(f(a[:],i,j+1)for i,k in enumerate(a)for j in range(x,k)if i-n)
Brute force search. Recursively subtracts a strictly increasing valuex from every indexi in the inputa, as long as i is not equal to the last picked indexn. This continues until all values in a are zero or the options to continue are exhausted.
Python 3, 106 bytes
def f(a,n=-1,x=0):a[n]-=x;return~-any(a)^any(f(1*a,i,j+1)for i,k in enumerate(a)for j in range(x,k)if i-n)
Brute force search. Recursively subtracts a strictly increasing value from every index in the input, as long as it is not equal to the prviously picked index. This continues until all values in the input are zero or the options to continue are exhausted.
Python 3, 111107 bytes
f=lambdadef f(a,n=-1,x=0):1a[n]-=x;return~-any(a)^any(f(a[:i]+[k+~j]+a[i+1:],i,j+1)for i,k in enumerate(a)for j in range(x,k)if i-n)
Brute force search. Recursively subtracts a strictly increasing value x from every index i in the input a, as long as i is not equal to the last picked index n. This continues until all values in a are zero or the options to continue are exhausted.
Python 3, 111 bytes
f=lambda a,n=-1,x=0:1-any(a)^any(f(a[:i]+[k+~j]+a[i+1:],i,j+1)for i,k in enumerate(a)for j in range(x,k)if i-n)
Brute force search. Recursively subtracts a strictly increasing value x from every index i in the input a, as long as i is not equal to the last picked index n. This continues until all values in a are zero or the options to continue are exhausted.
Python 3, 107 bytes
def f(a,n=-1,x=0):a[n]-=x;return~-any(a)^any(f(a[:],i,j+1)for i,k in enumerate(a)for j in range(x,k)if i-n)
Brute force search. Recursively subtracts a strictly increasing value x from every index i in the input a, as long as i is not equal to the last picked index n. This continues until all values in a are zero or the options to continue are exhausted.
Python 3, 114111 bytes
f=lambda a,n=-1,x=0:~1-any(a)^any(f(a[:i]+[k+~j]+a[i+1:],i,j+1)for i,k in enumerate(a)for j in range(x,a[i]k)if i-n)
Brute force search. Recursively subtracts a strictly increasing value x from every index i in the inputa, as long as i is not equal to the last picked index n. This continues until all values in a are zero or the possibilitiesoptions to continue are exhausted.
Python 3, 114 bytes
f=lambda a,n=-1,x=0:~-any(a)^any(f(a[:i]+[k+~j]+a[i+1:],i,j+1)for i,k in enumerate(a)for j in range(x,a[i])if i-n)
Brute force search. Recursively subtracts a strictly increasing value x from every index i in the input, as long as i is not equal to the last picked index n. This continues until all values in a are zero or the possibilities to continue are exhausted.
Python 3, 111 bytes
f=lambda a,n=-1,x=0:1-any(a)^any(f(a[:i]+[k+~j]+a[i+1:],i,j+1)for i,k in enumerate(a)for j in range(x,k)if i-n)
Brute force search. Recursively subtracts a strictly increasing value x from every index i in the inputa, as long as i is not equal to the last picked index n. This continues until all values in a are zero or the options to continue are exhausted.