Result

AC

Duration

915ms

Code [DL]

a=require("fs").readFileSync(0);for(i=0;i+51<a.length;)a[i+51]|=a[i++];for(;a[++i]!=116;)a[i]|=a[i-1];console.log(""+a)

stdin

                 T                                
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
                                                  
   K                                              

stdout

                 T                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
                 t                                
   kkkkkkkkkkkkkkt                                

stderr

strace