3 added 1 character in body
source | link

Perl 5, 9690 + 1 (-p) = 9791 bytes

@a=0..3*$_;@a[$d3*$_;$_=(map{@a[$d,$s]=@a[$s=$a[$_]+$a[$_-1],$d=abs$a[$_]-$a[$_-1]],push@r,$a[1]for 1]];$a[1]}1..$_;$_=pop@r$_)[-1]

Try it online!Try it online!

Perl 5, 96 + 1 (-p) = 97 bytes

@a=0..3*$_;@a[$d,$s]=@a[$s=$a[$_]+$a[$_-1],$d=abs$a[$_]-$a[$_-1]],push@r,$a[1]for 1..$_;$_=pop@r

Try it online!

Perl 5, 90 + 1 (-p) = 91 bytes

@a=0..3*$_;$_=(map{@a[$d,$s]=@a[$s=$a[$_]+$a[$_-1],$d=abs$a[$_]-$a[$_-1]];$a[1]}1..$_)[-1]

Try it online!

2 deleted 17 characters in body
source | link

Perl 5, 11196 + 1 (-p) = 11297 bytes

@a=0..3*$_;$t=$a[$d=abs$a[$_]-$a[$_3*$_;@a[$d,$s]=@a[$s=$a[$_]+$a[$_-1]]1],$a[$d]=$a[$s=$a[$_]+$a[$_$d=abs$a[$_]-$a[$_-1]],$a[$s]=$t,push@r,$a[1]for 21..$_;$_=$r[-1]$_;$_=pop@r

Try it online!Try it online!

Perl 5, 111 + 1 (-p) = 112 bytes

@a=0..3*$_;$t=$a[$d=abs$a[$_]-$a[$_-1]],$a[$d]=$a[$s=$a[$_]+$a[$_-1]],$a[$s]=$t,push@r,$a[1]for 2..$_;$_=$r[-1]

Try it online!

Perl 5, 96 + 1 (-p) = 97 bytes

@a=0..3*$_;@a[$d,$s]=@a[$s=$a[$_]+$a[$_-1],$d=abs$a[$_]-$a[$_-1]],push@r,$a[1]for 1..$_;$_=pop@r

Try it online!

1
source | link

Perl 5, 111 + 1 (-p) = 112 bytes

@a=0..3*$_;$t=$a[$d=abs$a[$_]-$a[$_-1]],$a[$d]=$a[$s=$a[$_]+$a[$_-1]],$a[$s]=$t,push@r,$a[1]for 2..$_;$_=$r[-1]

Try it online!