Make is_bst and is_aa more concise