Question: I want to implement a profile popup like Books app on iOS. Do you know any package or something to make this? Thank a lot.

GIF below shows the behavior that I want to implement:
<https://gph.is/g/EvAxvVw>

Answer: 
Use `in`: This will be simpler 

```sh
if a in ('A', 'U'):
    #do something 

```

Understanding your code.

```sh
if (a == ("A" or "U")):
   # do something

```

Python checks for `"A" or "U"` which `"A"` is return because of how truthfulness works. If the first is true, then the `or` is not evaluated. Since only empty string is False, the first none empty string will be selected and there your code is equivalent to:

```sh
if (a == "A"):
   # do something

```
It's not related to python. You can't further simplify the 2nd equation. 

a == "A" is one boolean -> x
a == "U" is one boolean -> y

x || y -> simplified version. 

Also, you can't apply distributive law to equality Operators(==, <, >). 

You can use the membership operator `in` check achieve above. 

```
if a in ["A", "U"]:
  do_something()

```