I am curious about the distribution of (maximum) run length given
k independent trials when $p(X=1)=p_1, p(X=2)=p_2, ..., p(X=n)=p_n.$
For example, for a coin tossing for 3 independent trials,
$p(mrl=3)=2*(1/2)^3 for HHH, TTT $
$p(mrl=2)=4*(1/2)^3 for HTT, THH, HHT, TTH $
But what if for general n and k?
My guess would be $E(mrl)=log_k n$ for uniform distribution