Added code from two sigma interview