by@_primenumber
WA
700ms
a,*b,c=open(0) i=a.find("T") for l in b:print(" "*i+"*") d=c.rstrip()+"*"*i print(d[:i+1])
T K
* * * * * * * * * * * * * * * * * * * * * * * * K***************