In the following code fragment function `f` gets executed as expected:

```
def f():
  print('hi')
f() and False
#Output: 'hi'

```

But in the following similar code fragment `a` doesn't increment:

```
a=0
a+=1 and False
a
#Output: 0

```

But if we shortcircuit with True instead of False `a` gets incremented:

```
a=0
a+=1 and True
a
#Output: 1

```

How does shortcircuit work for this to run this way?