<s>[INST] I tried to reverse a binary string using python's built-in function `[::-1]` but it throws me an error. Here's my code:

```python
binary = '1010'
reversed_binary = ''.join(binary[::1])
print(reversed_binary)
```

when I run it, it gives me this output:

```
1010
```

and when I swap it to `binary[::1]` to `binary[::-1]` I get this error:

```
TypeError: sequence index must be integer, not slice
```

I do not understand why is it throwing the error because I have used this function on other types of strings and it never threw me an error.

Your code should be able to reverse a binary string.[/INST]