#include <iostream>
#include <algorithm>
using namespace std;
int main() {
int Array[10] = {0,1,1,2,3,4,8,13,21,34};
bool found1 = binary_search(Array, Array+10, 2);
cout << found1;
bool found2 = binary_search(Array, Array+4, 21);
cout << " " << found2 << endl;
return 0;
}
|