MathDB
2017 Combinatorics #10: Number of Words

Source:

February 20, 2017

Problem Statement

Compute the number of possible words w=w1w2w100w=w_1w_2\dots w_{100} satisfying: \bullet ww has exactly 5050 AA's and 5050 BB's (and no other letter). \bullet For i=1,2,,100i=1,2,\dots,100, the number of AA's among w1,w2,,wiw_1, w_2, \dots, w_i is at most the number of BB's among w1,w2,,wiw_1, w_2, \dots, w_i. \bullet For all i=44,45,,57i=44,45,\dots,57, if wiw_i is a BB, then wi+1w_{i+1} must be a BB.