• + 0 comments

    Simple Python Solution:

    def smallestSizeSubsequence(n, A):
        total = sum(A)
        result = 0 if total%2 == 0 else 1 if len(A)>1 else -1
        return result