Simple binary search implemented in ActionScript 3.