I need to parse text of text file into two categories:

```
University
Location(Example: Lahore, Peshawar, Jamshoro, Faisalabad)

```

but the text file contain following text:
"Imperial College of Business Studies, Lahore"  

"Government College University Faisalabad"  

"Imperial College of Business Studies Lahore"  

"University of Peshawar, Peshawar"  

"University of Sindh, Jamshoro"  

Code:

```
for l in content:
    rep = l.replace('"','')
    if ',' in rep:
        uni = rep.split(',')[0]
        loc = rep.split(',')[-1].strip()
    else:
        loc = rep.split(' ')[-1].strip()
        uni = rep.split(' ').index(loc)

```

It Return following Output, Where 3 and 5 are index value before cities:

* 3 represents Government College University
* 5 represents Imperial College of Business Studies

Uni: Imperial College of Business Studies Loc: Lahore  

Uni: 3 Loc: Faisalabad  

Uni: 5 Loc: Lahore  

Uni: University of Peshawar Loc: Peshawar  

Uni: University of Sindh Loc: Jamshoro  

**I want the Program to return me the string value against index value 3 & 5.**