by@akouryy1
AC
665ms
$/=0;$_=<>;s/([^T]{50})./$1T/g;0while s/K /KK/g;print
T K
T T T T T T T T T T T T T T T T T T T T T T KKKKKKKKKKKKKKKKKKKKKT