If i need to ask a condition on every element of a numpy.ndarray of integers, do I have to use a for loop

```
for i in range(n):
    if a[i] == 0:
        a[i] = 1   

```

or can I ask the question using [:] syntax

```
if a[:] == 0:
    #...

```

I know the previous is wrong, but is there any way of doing something similar?