Bubble sort query

What if item is placed twice let say at index 2 and 3 ?
Can binary search return both the indexes?
If yes then how?

binary search algo can return only one index…but you can modify your binary search to return either the first occurance or last occurance of the number to be searched