Let $I$ be the Dynkin diagram vertex set and $K$ be a proper nonempty subset of it. Let $w_0^K$ be the longest word of the Dynkin subdiagram $K$, which might be a disjoint union of connected Dynkin diagrams.
I saw in the paper "Preprojective algebras and partial flag varieties" by Geiss, Leclerc and Schroer the following statement:
“We can write $w_0 = w^K_0 v_K$ with $\ell(w^K_0) + \ell(v_K) = ℓ(w_0).$ Therefore there exist reduced words $i$ for $w_0$ starting with a factor $(i_1,\dotsc,i_{r_K})$ which is a reduced word for $w^K_0$.”
I could run this through examples, like writing the longest element $w_0=s_3s_2s_3s_1s_2s_3s_1s_2s_1$ of type $B$ as $w_0=\boldsymbol{s_1s_2s_1} {s_3s_2s_1s_3s_2s_3}$, if $K=\{3\}$$K=\{1،2\}$.
I was wondering if there is an algorithm showing how to do this in general, at least if the size of $K$ is known, like $|K|=1$$|K|=|I|-1$.