Question d’entretien chez Jane Street

Two combinatorics/probability questions.