A list is a row of values in order: [3, -1, 0, 8]. Write for v in values and v takes the next element on each turn. You do not need to know how many there are; the loop ends when the list does.
count = 0for v in values:if v > 0:count += 1return count
count += 1 is short for count = count + 1.The same pattern collects a sum: total += v. The only difference is what you add inside the loop: 1 when counting, the element itself when summing.