Driver code
static public void Main ( ) { List < int > A = new List < int > ( ) ; int [ ] arr = { - 2 , 10 , 100 , 250 , 32315 } ; for ( int i = 0 ; i < arr . Length ; i ++ ) { A . Add ( arr [ i ] ) ; } Console . WriteLine ( bsearch ( A , 10 ) ) ; } }