Lakera interview question

Program a binary sort and descibe the complexity