Question: I have a string:

`/1/2/3/anystring as follows here even forward slashes/////`

how can i capture the groups

`(1) (2) (3) (anystring as follows here even forward slashes/////)`

or conditionally if (2) or (3) cannot be captured then capture one (1) or (1)/(2) or (1)(2)(3) or all

i have tried

`^/(.*)/(.*)/(.*)/(.*)`

but it doesn't capture `/1/2/` or `/1/` or `/1/2/3/`.

Answer: 
If you are unable to install MySQL CLient in Pycharm, try opening the Terminal (Alt+F12) and write the command

```
pip install --only-binary :all: mysqlclient

```

This might help!
From Windows Command Prompt / Linux Shell

install using wheel

```
pip install wheel

```

Download 32 or 64 Bit version from <http://www.lfd.uci.edu/~gohlke/pythonlibs/#mysql-python>

**64-Bit**

```
pip install MySQL_python-1.2.5-cp27-none-win_amd64.whl

```

**32-Bit**

```
pip install MySQL_python-1.2.5-cp27-none-win32.whl

```

**Using Anaconda2:**

Open a Command Prompt

```
$ conda install mysql-python

```

Press y to proceed with installation