> For the complete documentation index, see [llms.txt](https://docs.arkannis.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.arkannis.net/programming/courses/python-pcap-31-03-course/lists-tuples-and-dictionaries/finding-index-positions-in-lists-and-counting-duplicates.md).

# Finding Index positions in Lists and counting duplicates

## Finding Index positions

```python
my_list = ['a', 'b', 'c', 'd']

idx_pos = my_list.index('a') # This will print the index position. I.e 2
# The variable will return an INT
```

## Counting duplicates

```python
my_list = ['a', 'b', 'c', 'd', 'c', 'c']
c_count = my_list.count('c') # The variable will return an INT
```

{% hint style="info" %}
`NOTE:`

* Any `SLICING` that you do with a `LIST` `returns` a `LIST`
* Any `SLICING` that you do with a `TUPLE` `returns` a `TUPLE`
  {% endhint %}
