Find the number of how many indexes have the same item

Dear GH Community,

I need a little help with a List edit.
Is a process which I can solve by having only one branch, but with more branches I have some problems.

I have a list with a series of numbers in ascending order. In some cases I have only one item with the same number, in other cases I have multiple items with the same number. I need to know how many indexes have the same number in each branch. (6.6 KB)

Thanks and best regards

Here are a couple of options: (13.4 KB)

Thanks for the help Adam