How is the Output 1

In Q2, how the binary search output is 1?

hello @alamsarfraz422

pls share the question with me.

Q2. Algorithms STL#2

Choose the correct output and time complexity for the following code :

list< int > myList = { 2, 6, 12, 13, 15, 18, 20}; cout << binary_search(myList.begin(), myList.end(), 20) ;

this the question please tell why output is 1???