g | x | w | all
Bytes Lang Time Link
100R240605T200701Zint 21h
091Java JDK180305T142633ZOlivier
072PowerShell190312T091650Zmazzy
062Ruby180305T151847ZAsone Tu
069Python 2 / 3180305T170355ZAsone Tu
153Java180307T155532ZAmir M
025Husk180312T051211ZEsolangi
025CJam180311T173017ZEsolangi
030APL Dyalog Classic180310T150939Zngn
033K oK180310T151707Zngn
085PHP180307T224757ZM4tini
053Ruby180307T135909ZKirill L

R, 100 bytes

\(S,`!`=utf8ToInt,x=diff(!S)-1)o=Map(\(j,k)cat(intToUtf8(c(rep(!"TAPE",6)[0:j],k))),c(0,x*(x>0)),!S)

Attempt This Online!

This solution is based on the subtraction of two adjacent characters codes (diff). TAPE repeated 6 times gives 24 chars, which corresponds to the maximal distance - from \$A\$ to \$Z\$. This long vector is being subset each time to the appropriate length (from 0 to 24) and inserted between the pairs of letters.

Java (JDK), 91 bytes

s->{var p='z';for(var c:s)System.out.print("ETAP".repeat(9).substring(1,c>p?c-p:1)+(p=c));}

Try it online!

Explanation

s->{                       // char[]-accepting lambda consumer, printing a String
 var p='z';                //  store the previous character
 for(var c:s){             //  for each character of the string
  System.out.print(        //   print...
   "ETAP".repeat(9)        //    "ETAP" repeated 9 times (to go above 26 chars)
    .substring(1,          //     of which, we substring c-p -1 characters
     c>p?c-p:1             //
    )                      //
   +(p=c)                  //    and append c, while also storing the previous character
  );

Credits

PowerShell, 72 bytes

-join($args|% t*y|%{for(;$p*(++$p-lt$_)){'TAPE'[$i++%4]}$i=0;$p=+$_;$_})

Try it online!

Ruby, 78 77 64 62 bytes

-1 byte thanks to Kevin Cruijssen

f=->s,*t{t[0]?s+('TAPE'*6)[0,[0,t[0].ord+~s.ord].max]+f[*t]:s}

Try it online!

Python 2 / 3, 70 69 bytes

f=lambda s,*t:t and s+('TAPE'*6)[:max(ord(t[0])+~ord(s),0)]+f(*t)or s

Try it online!

Java , 213 166 153 bytes

i->{String o="";for(int a=0,l=i.length;++a<=l;){char u=i[a-1],n;o+=u;if(a<l){n=i[a];o+="TAPETAPETAPETAPETAPETAPET".substring(0,n-u>0?n+~u:0);}}return o;}

try it online

    String o = "";
    for (int a = 0, l = i.length; ++a <= l; ) {              // for each character
        char u = i[a - 1];                                    //  current character
        o += u;                                               //  add current character to output string 
        if (a < l) {                                          //  if it's not the last one
            char n = i[a];                                    //  next character
            o += "TAPETAPETAPETAPETAPETAPET".substring(0, n - u > 0 ? n +~ u : 0); // fill with enough tape but only forward
        }
    }
    return o;

Please help me make it better.

Thanks to @cairdcoinheringaahing for the tip on whitespaces. Thanks to @R.M for the tip on tape string. Thanks to @KevinCruijssen for the lambda and expressions tips.

Husk, 26 25 bytes

ΣSoż+C1(moo↑¢¨tȦ9¨>0←Ẋ-mc

Try it online!

CJam, 27 25 bytes

q_:i2ew.{:-~0e>_"TAPE"*<}

Try it online!

Far, far from the other golfing languages, but I'm proud of this golf anyway.

Explanation

q                            Read the input
     ew                      And take windows of size
    2                          2
   i                           from the code points
  :                            of each of its characters.
        {               }    For each of these windows:
         :                     Reduce with
          -                      subtraction.
                                 Since there are only 2 elements, this just subtracts them.
             e>                Take the maximum
           ~                     of this difference's bitwise negation
            0                    and zero.
                                 This returns -n-1 if n is negative, and 0 otherwise.
                                 Call this new value m.
                      *        Repeat
                "TAPE"           the string "TAPE" m times.
               _       <       And then take the first m elements.
                             The result of this will be an array of strings which consist of
                             the string "TAPE" repeated the proper amount of times.
       .                     Zip this array with the original input.
                             Since the original input is one element longer than this array,
                             the nothing is pushed after the final character.
                             Implicitly print everything.

APL (Dyalog Classic), 30 bytes

{∊⍵,¨⍨⍴∘'TAPE'¨0,0⌈-1+2-/⎕a⍳⍵}

Try it online!

{ } anonymous function with argument

⎕a⍳⍵ find indices of its chars in the alphabet

2-/ pairwise differences (prev minus next)

1+ add 1

- negate

0⌈ max(0, ...)

0, prepend a 0

⍴∘'TAPE'¨ reshape cyclically the string 'TAPE' to each

⍵,¨⍨ append each char from the argument to the corresponding reshaped string

flatten

K (oK), 33 bytes

{,/((0|-1+0,1_-':x)#\:"TAPE"),'x}

Try it online!

{ } anonymous function with argument x

-':x subtract each prior (use an imaginary 0 before the first item)

1_ drop first item

0, prepend a 0

-1+ add -1

0| max(0, ...)

(...)#\:"TAPE" reshape the string "TAPE" to each item from the list on the left

(...),'x append the corresponding character from x to each reshaped string

,/ concatenate all

PHP, 85 bytes

$s=str_split($argv[1]);foreach($s as$l)echo str_pad($l,ord(next($s))-ord($l),'TAPE');

Try it online!

Explanation

$s = str_split($argv[1]);   // convert the parameter string to an array
foreach($s as $l)           // loop the array
echo str_pad(               // print
  $l,                       // the letter
  ord(next($s)) - ord($l),  // calculate the distance to the next letter using ASCII values
  'TAPE'                    // padding string
);                          // profit!

Ruby, 59 53 bytes

->s{s.reduce{|x,y|x+y.rjust(y.ord-x[-1].ord,"TAPE")}}

Try it online!

This is actually pretty straightforward - we take input as split our string into an array of chars (thanks to Asone Tuhid for pointing this out) and apply reduce operation, where we justify each char to the required length using "TAPE" as filler string.