Question DSA-SRCH-0007
EasyWhat is the output of this code?
import bisect
print(bisect.bisect_left([1, 3, 5, 5, 7], 5))
- A.
4
- B.
1
- C.
Show answer and explanation
Answer: D
bisect_left returns the first index where 5 could be inserted while keeping order: index 2.