text:
Tribute to Stan Lee
Unfortunately one of the greatest comic book writers passed away yesterday afternoon. Lots of Hollywood stars, musicians, actors, and many other people are paying tribute to this awesome writer, so we must do something as well.
Challenge
Print The Avengers Logo
Note: You may use any other character in place of # other than a space character; while you must use a space character for the space

In ASCII-art
              ######
      ###############
    #####    ##########
  ####       ####### ####
 ###        #### ###   ###
###         #### ###    ###
###        ####  ###    ###
###        ####  ###    ###
###       ####   ###    ###
###       ####   ###    ###
###      ###########    ###
###      ###########    ###
###     ####     ###    ###
###     ###      ###    ###
 ####  ####           ####
  ########         ######
      #################
      ###

Optional
Who was (in your opinion) his greatest hero and villain in the entire marvel universe?

Standard code-golf rules apply

What happened to the → in Ⓐ?

@Adám 2 Reasons. I believe that the arrow means the continuation of the series (in this case the comics about avengers). Since Stan passed away there wont be a continuation of it (In my opinion, it is not the same without Stan). That is one of the reasons

The second one is that I didnt know how to draw it :c

Are the trailing spaces required?

@Scoots no, it is not required as long as your output looks the same

Lmao, no one answered your essay question, not even in passing. This is peak codegolf.SE.

Jelly, 62 59 58 bytes
“ḢE{ɠs{Ƒ0Ṇṁỵ8ỊṢṂƊeLṫfIWẈḞ'ʠJ£ṗɱ\çoȧ?ƒnØẆƥṂ⁷ɱ’b12ĖŒṙḂa⁶s27Y

Thanks to @JonathanAllan for golfing off 1 byte!
Try it online!
How it works
“ḢE{ɠs{Ƒ0Ṇṁỵ8ỊṢṂƊeLṫfIWẈḞ'ʠJ£ṗɱ\çoȧ?ƒnØẆƥṂ⁷ɱ’

is a bijective base-250 integer literal, which uses the characters in Jelly's code page as digits.
The literal encodes the integer \$\scriptsize 10250938842396786963034911279002199266186481794751691439873548591280332406943905758890346943197901909163\$, which b12 converts to duodecimal, yielding \$\scriptsize 30b620b40ba54a64771433841333139413468423468423467433467433466b466b465453465363431424b43896860ba3_{12}\$.
There are some zeroes, because 14 spaces (e.g.) are encoded as 3 spaces, 0 hashes, and 11 spaces. This maintains the base small (the largest run consists of 17 hashes), without adding any additional logic to the decoder.
Ė (enumerate) prefixes every base-12 digit by its 1-based index, then Œṙ performs run-length decoding.
Now, for each integer in the resulting array, Ḃ extracts the least significant bit, then a⁶ (AND space) replaces ones with spaces, while leaving zeroes unchanged.
Finally, s27 splits the unformatted character array into chunks of length 27, which Y separates by linefeeds.

R, 198, 173, 163, 157, 144, 142 bytes
write(rep(rep(c(' ',4),44),utf8ToInt("NFMOJEDJFDGGADCCHDACCCACIDACDFHDBCDFHDBCDFGDCCDFGDCCDFFKDFFKDFEDECDFECFCDCADBDKDCHIFHQJC")-64),1,27,,'')

Try it online!
Also R honors to the great Stan.
Notes :

instead of the character # we've used the character 4 because saves 2 bytes and :

it's a reference to the Fantastic Four and/or the next Avengers 4 movie
it's like we're repeating the logo inside the logo (since 4 seems a mini "slanted" A)

-15 bytes thanks to @Giuseppe

Explanation :
Applying a Run Length Encoding (rle function) on the characters of the string (excluding '\n') returns 88 repetitions of the alternating <space>,<hash>,<space>,<hash>,<space>,<hash>....
The 88 repetitions are all values in the range [1,17] hence, summing 64 we get the code points of the letters [A...Q] obtaining the string : "NFMOJEDJFDGGADCCHDACCCACIDACDFHDBCDFHDBCDFGDCCDFGDCCDFFKDFFKDFEDECDFECFCDCADBDKDCHIFHQJC"
Hence the code basically does the opposite operations :
v <- utf8ToInt("NFMOJEDJFDGGADC...")-64  # convert the string back to [1...17] vector

e <- rep(rep(c(' ',4),44),v)             # perform the inverse of rle function obtaining an
                                         # expanded vector of <space>'s and <four>'s

write(e,1,27,,'')                        # write the vector to stdout arranging it
                                         # in rows of maximum 27 characters

Your solution is nicer, but your own gzip 2-parter gives 89+47 = 136 bytes.

@J.Doe : ahah I even forgot to have used that approach! please post it as your own answer :)

Since we can use any character for #, using 0 in place of "#" should save 2 more bytes. @J.Doe that may work better for your gzip as well.

Bubblegum, 71 66 65 64 bytes
0000000: 95 91 21 12 00 20 08 c0 3a af 90 ff 7f 52 4e 58  ..!.. ..:....RNX
0000010: 58 93 25 d8 8a 27 47 e4 23 66 01 2c ce b1 3c 12  X.%..'G.#f.,..<.
0000020: 5f 5b 17 7c 81 ed 31 28 4e 6e a4 6d 23 ad 5b c2  _[.|..1(Nn.m#.[.
0000030: ae 25 83 9a 94 1a 2f 6f 05 fc e5 f0 73 13 f9 0b  .%..../o....s...

Thanks to @ovs for golfing off 1 byte!
Try it online!

How exactly do you golf bytes off of Bubblegum? I assumed the strategy would be to try each compression algorithm and pick the one that compresses your input the most. Where do you go from there?

@Cowabunghole The first golf removed the trailing spaces, the second one increased the number of zopfli iterations (ovs's idea), and the last one switched from # to !.

C (gcc), 244 243 242 bytes
#define z <<10|117441415
x[]={8064,2097088,8142832,31473596,58751886,30 z,60 z,60 z,120 z,120 z,255 z,255 z,480 z,448 z,63897630,33423612,2097136,1835008};b(_,i){i&&b(_/2,i-1),putchar(32+_%2*3);}main(_){_<19&&b(x[_-1],27)&puts("")&main(_+1);}

Try it online!
-1 Thanks to Peter Cordes
-1 Thanks to ceilingcat
Uses bit compression.
Explanation:
The goal is to print a set of numbers in binary using space and # as digits which represent the logo. A bit of bash magic converts the logo to binary masks:
echo "ibase=2;$(<code which echoes the logo [see my bash solution for example]> | tr ' #' 01)" | bc

This results in the binary 'numbers' being:
8064,2097088,8142832,31473596,58751886,117472135,117502855,117502855,117564295,117564295,117702535,117702535,117932935,117900167,63897630,33423612,2097136,1835008

There is an obvious pattern in the middle where every line contains ###              ###     ###
We can save some space by compressing that middle section based on saving that pattern and OR-ing against it. In addition, all of those lines merely add some stuff to the left of the middle section, so we make the z macro which takes ?????????????? and converts it into ###??????????????###     ###. This involves bitshifting left by 10 and OR-ing with the binary of that pattern, which is 117441415.
Now we can more easily understand the code:
#define z <<10|117441415 // Define z to be the compression defined above
x[]={                    // Define x to be an array storing each line's number
8064,2097088,8142832,    // The first 5 lines are uncompressed
31473596,58751886,
30 z,60 z,60 z,120 z,    // The middle 9 lines are z-compressed
120 z,255 z,255 z,480 z,
448 z,
63897630,33423612,       // The last 4 lines are uncompressed
2097136,1835008};
b(_,i){                  // we also need a function to print n-bit binary numbers
i&&                      // i is the bit counter, we recurse until its zero
b(_/2,i-1),              // each recursive call halves the input and decrements i
putchar(" #"[_%2]);}     // this just prints the correct character
main(_){                 // this is the main function, called as ./? will have 1 in _ (argc)
_<19?                    // if _ is less than 19 then...
  b(x[_-1],27),          // print the binary expansion of x[_-1]
  puts(""),              // print a new line
  main(_+1)              // recurse with _++
:0;}

Can x?y:0 be replaced with x&&y, or does  operator precedence not work?  Maybe with & instead of , separating the 3 function calls because & has higher precedence than && or , (https://en.cppreference.com/w/c/language/operator_precedence).  Or not because only , provides a sequence point for the printing vs. recursion to avoid undefined behaviour.

It doesn't work with && indeed because of the precedence, while & doesn't short-circuit. As of yet I haven't found a shorter alternative, though I wouldn't rule one out.

I meant with & or | or ^ replacing , (because they don't short-circuit) and && replacing ? (because it does).  Like _<19 && b() & puts() & main(_+1); (spaces added for readability).  The order of evaluation is undefined, which may actually undefined behaviour because of unsequenced side-effects on stdout https://en.cppreference.com/w/c/language/eval_order, but in practice any given compiler will pick some order for a given set of target + options.

Ahh, I see what you mean. You're right - that does work! -1 byte.

You don't need the space between the macro and the definition.

241 bytes

Building on @Zacharý 239 bytes

Python 2, 129 bytes
00000000: 2363 6f64 696e 673a 4c31 0a70 7269 6e74  #coding:L1.print
00000010: 2778 da95 9141 0e5c 3021 0803 ef7d 4593  'x...A.\0!...}E.
00000020: feff 8f9b 5d14 5c6e f1b0 f622 7422 2890  ....].\n..."t"(.
00000030: 2e7d 5a09 dc4b 19cb bc53 84d1 4a6a 5960  .}Z..K...S..JjY`
00000040: 116e 3f42 c290 b3f7 c0bc 76cf 549d 6ed8  .n?B......v.T.n.
00000050: f8fa 5f26 0b0e 8c93 d5cb 35f6 b1e7 a939  .._&......5....9
00000060: 9e98 e769 47b9 87d6 cdf5 5c30 3030 32c0  ...iG.....\0002.
00000070: 4029 272e 6465 636f 6465 2827 7a69 7027  @)'.decode('zip'
00000080: 29                                       )

Try it online!

129 bytes, I removed the trailing \n from the compressed string.

Charcoal, 71 68 67 bytes
←⁸↙Ｐ⁵↘←⁴↓Ｐ³↙Ｆ⁹⟦³⟧→Ｐ⁴↘Ｐ⁶↘‖ＯＭ←←¹⁷↘Ｆ⁹«Ｐ⁺³›ι³↑Ｐ⁴↗¿⁼ι²Ｂ⁸±²»↘→ＵＯ³¦¹⁴ＵＭＫＡ#

Try it online! Link is to verbose version of code. Explanation:
←⁸↙Ｐ⁵↘←⁴↓Ｐ³↙Ｆ⁹⟦³⟧→Ｐ⁴↘Ｐ⁶

Output half of the circle.
↘‖ＯＭ←←¹⁷↘

Reflect it and draw in the bottom.
Ｆ⁹«Ｐ⁺³›ι³↑Ｐ⁴↗¿⁼ι²Ｂ⁸±²»

Draw the left arm and crossbar of the A.
↘→ＵＯ³¦¹⁴

Draw the right arm of the A.
ＵＭＫＡ#

Change all the characters to #s.

T-SQL, 341 338 bytes
DECLARE @ CHAR(2000)=REPLACE(REPLACE(REPLACE(
'PRINT SPACE(14*6&$6*15&$4*5$4*10&$2*4$7*7$1*4&$1*3$8*4$1*3$3*3&*3$9*4$1*3$4
 *3&*3$8*4$2*3$4*3&*3$8*4$2*3$4*3&*3$7*4$3*3$4*3&*3$7*4$3*3$4*3&*3$6*11$4*3&
 *3$6*11$4*3&*3$5*4$5*3$4*3&*3$5*3$6*3$4*3&$1*4$2*4$11*4&$2*8$9*6&$6*17&$6*3)'
,'*',')+REPLICATE(''#'','),'$',')+SPACE('),'&',')+(''
''')EXEC(@)

The first 4 line breaks are for readability only, the final line break is part of a string literal.
Similar to my Adam West tribute, I've manually encoded a long string, and made the following replacements:

*7 gets replaced by +REPLICATE('#',7)
$4 gets replaced by +SPACE(4)
& gets replaced by a line break inside quotes

This results in a massive SQL command string:
PRINT SPACE(14)+REPLICATE('#',6)+('
')+SPACE(6)+REPLICATE('#',15)+('
')+SPACE(4)+REPLICATE('#',5)+SPACE(4)+REPLICATE('#',10)+('
')+SPACE(2)+REPLICATE('#',4)+SPACE(7)+REPLICATE('#',7)+SPACE(1)+REPLICATE('#',4)+('
')+SPACE(1)+REPLICATE('#',3)+SPACE(8)+REPLICATE('#',4)+SPACE(1)+REPLICATE('#',3)+SPACE(3)+REPLICATE('#',3)+('
')+REPLICATE('#',3)+SPACE(9)+REPLICATE('#',4)+SPACE(1)+REPLICATE('#',3)+SPACE(4)+REPLICATE('#',3)+('
')+REPLICATE('#',3)+SPACE(8)+REPLICATE('#',4)+SPACE(2)+REPLICATE('#',3)+SPACE(4)+REPLICATE('#',3)+('
')+REPLICATE('#',3)+SPACE(8)+REPLICATE('#',4)+SPACE(2)+REPLICATE('#',3)+SPACE(4)+REPLICATE('#',3)+('
')+REPLICATE('#',3)+SPACE(7)+REPLICATE('#',4)+SPACE(3)+REPLICATE('#',3)+SPACE(4)+REPLICATE('#',3)+('
')+REPLICATE('#',3)+SPACE(7)+REPLICATE('#',4)+SPACE(3)+REPLICATE('#',3)+SPACE(4)+REPLICATE('#',3)+('
')+REPLICATE('#',3)+SPACE(6)+REPLICATE('#',11)+SPACE(4)+REPLICATE('#',3)+('
')+REPLICATE('#',3)+SPACE(6)+REPLICATE('#',11)+SPACE(4)+REPLICATE('#',3)+('
')+REPLICATE('#',3)+SPACE(5)+REPLICATE('#',4)+SPACE(5)+REPLICATE('#',3)+SPACE(4)+REPLICATE('#',3)+('
')+REPLICATE('#',3)+SPACE(5)+REPLICATE('#',3)+SPACE(6)+REPLICATE('#',3)+SPACE(4)+REPLICATE('#',3)+('
')+SPACE(1)+REPLICATE('#',4)+SPACE(2)+REPLICATE('#',4)+SPACE(11)+REPLICATE('#',4)+('
')+SPACE(2)+REPLICATE('#',8)+SPACE(9)+REPLICATE('#',6)+('
')+SPACE(6)+REPLICATE('#',17)+('
')+SPACE(6)+REPLICATE('#',3)

Which, when run, produces the necessary output.
Long, but still better than my best set-based solution (463 bytes):
SELECT SPACE(a)+REPLICATE('#',b)+SPACE(c)+REPLICATE('#',d)
      +SPACE(e)+REPLICATE('#',f)+SPACE(g)+REPLICATE('#',h)
FROM(VALUES(7,0,7,6,0,0,0,0),(6,8,0,7,0,0,0,0),(4,5,4,5,0,5,0,0),(2,4,7,7,1,4,0,0),
           (1,3,8,4,1,3,3,3),(0,3,9,4,1,3,4,3),(0,3,8,4,2,3,4,3),(0,3,8,4,2,3,4,3),
           (0,3,7,4,3,3,4,3),(0,3,7,4,3,3,4,3),(0,3,6,6,0,5,4,3),(0,3,6,6,0,5,4,3),
           (0,3,5,4,5,3,4,3),(0,3,5,3,6,3,4,3),(1,4,2,4,5,0,6,4),(2,8,9,6,0,0,0,0),
           (6,9,0,8,0,0,0,0),(6,3,0,0,0,0,0,0))t(a,b,c,d,e,f,g,h)

can drop 2 chars using CHAR(8000) instead of VARCHAR(max) (the huge command is 1453 bytes)

Thanks, @Shameen. I tried to save one more and use CHAR(2E3) but it didn't seem to like that. I also saved a byte by using a line break literal instead of CHAR(13).

C (gcc), 174 168 164 160 bytes
-6 bytes thanks to Dennis.
i,j;main(l){while(i="NFMOJEDJFDGGADCCHDACCCACIDACDFHDBCDFHDBCDFGDCCDFGDCCDFFKDFFKDFEDECDFECFCDCADBDKDCHIFHQJC"[j++]&63)for(;i;)putchar(l++%28?--i,35-j%2*3:10);}

Try it online!

05AB1E, 101 88 64 bytes
„# •∍ΔÎë,½=bOÅ.âαUΔ'òõƶαÔγλ#xÆ]~”FbćÁ˜Ð”wнQ_wā©•12вεN>yи}˜èJ27ô»

-24 bytes by creating a port of @Dennis♦' Jelly answer.
Try it online.
Explanation:
„#                     # Push string "# "
   •∍ΔÎë,½=bOÅ.âαUΔ'òõƶαÔγλ#xÆ]~”FbćÁ˜Ð”wнQ_wā©•
                      '# Push compressed integer 10250938842396786963034911279002199266186481794751691439873548591280332406943905758890346943197901909163
     12в               # Convert to Base-12 as list: [3,0,11,6,2,0,11,4,0,11,10,5,4,10,6,4,7,7,1,4,3,3,8,4,1,3,3,3,1,3,9,4,1,3,4,6,8,4,2,3,4,6,8,4,2,3,4,6,7,4,3,3,4,6,7,4,3,3,4,6,6,11,4,6,6,11,4,6,5,4,5,3,4,6,5,3,6,3,4,3,1,4,2,4,11,4,3,8,9,6,8,6,0,11,10,3]
        ε    }         # Map each `y` to:
         N>            #  The index+1
           yи          #  Repeated `y` amount of times
              ˜        # Flatten the list
               è       # Index each in the string "# " (with automatic wraparound)
                J      # Join everything together
                 27ô   # Split into parts of length 27
                    »  # And join by newlines

See this 05AB1E tip of mine (sections How to compress large integers? and How to compress integer lists?) to understand how the compression of the integer and list works.

You can save two bytes like this: •∍ΔÎë,½=bOÅ.âαUΔ'òõƶαÔγλ#xÆ]~”FbćÁ˜Ð”wнQ_wā©•12вDg„ #s∍S×J27ô» by replacing „#  and εN>yи}˜è with Dg„ #s∍S×

JavaScript (ES6), 173 170 bytes
_=>`tc
du
9a9k
58fe38
36h83676
6j83!h85!h85!f87!f87!dm96
6dm96
6b8b!b6d696
3858n8
5gjc
dy
d6`.split`!`.join`696
6`.replace(/./g,c=>'# '[(k=parseInt(c,36))&1].repeat(k/2))

Try it online!

Node.js, 163 bytes
Provided that an array of strings is a valid output:
_=>Buffer(`.&-/*%$*&$''!$##($!###!#)$!#$&($"#$&($"#$&'$##$&'$##$&&+$&&+$&%$%#$&%#&#$#!$"$+$#()&(1*#2`).map(c=>s+='# '[x^=1].repeat(c-32),s=x='')&&s.match(/.{27}/g)

Try it online!

Canvas, 74 73 71 bytes
ｑｃ２－Ａｚ↓n⁴╫ｍ┬ｆｆ╷＼_↘Tｔ)%⁵6＞Ｙy7pＱ∔Ｉ％SIŗ＋T＾≤?↔↖¶８^`O‾+Ｏ│≤n≡j↶82„２┬｛ #＠］∑‾＋ｎ

Try it here!

im just curious, how u guys type those chars? u have special keyboard or something?

@NikkoKhresna 85% of my code is the data generated by a generator, but the last 11 bytes doing all the logic were typed in the Canvas dev mode and spamming of tab after every char. That's only the case for me & Canvas though, e.g. AFAIK all of Jellys chars are typable with linux compose sequences.

@NikkoKhresna yeah, a lot of languages have different ways of typing the chars. some are typable with US keyboard (Jelly), some require pasting, and some (Charcoal, Actually and Sesos afaik) have a sort of verbose mode which only requires you to know the command names

@NikkoKhresna Charcoal also has (a very, very outdated) Linux keyboard, and probably some other languages too

Bash, 192 176 bytes
dc<<<"16i2o81C0000 81FFFF0 9FE00FC BCF001E F070387 F078387 F03FF87 F03FF87 F01E387 F01E387 F00F387 F00F387 F007B87 B807B8E 9E03FBC 87C3FF0 81FFFC0 8001F80f"|tr 01 ' #'|cut -c2-

Try it online!
-16 thanks to manatwork
This is similar to my C answer, except it just uses a raw base-16 compression and passes it through bc, then uses tr to convert 1 to # and 0 to space. Each row has 1 appended to it and stripped off of it to maintain alignment.
Unfortunately dc is shorter than bc.

No need for ^. But even better, use cut -c2- instead of the sed part.

And also shorter with here-string instead of echo and even shorter with dc instead of bc: Try it online!

I'll give you the echo, but come on - dc for Stan Lee... you must be joking ;)

134 bytes

///, 170 bytes
/+/\/\///*/  +)/'$# +(/"$!+'/" +&/!#+%/"!
!+$/*!+"/**+!/###/""('*
(!!!'
"&#"!!&"
$#'$& &*
 !""& ! $
!"'& !%""&$%""&$%)$%)$%(&#%(&#%'&'!%'!"$"!
 &$#")
$&#"'!!*
(!!&#"
"$

Try it online!

Perl 6, 136 112 bytes
:128['?@~p<?x?aB~<|xpqpac`?@~x>q|<!Ca`||?x'.ords].base(2)~~TR/1/ /.comb(27)>>.say

Try it online!
Parses a base 128 number from the ordinal values of the compressed string, converts to base 2 and replaces the 1s with spaces. This uses zeroes as the main character. The string has like 9 null bytes, which was a bitch to type up in TIO. I would have used base 127 for the same amount of bytes, but no nulls, but that has a carriage return, which seems to be impossible to distinguish from a newline :(
Explanation:
:128['...'.ords]   # Convert the bytes of the string to base 128
.base(2)           # Convert to base 2
~~TR/1/ /          # Translate 1s to spaces
                   # Alternatively, this could be .split(1)
.comb(27)          # Split to strings of length 27
>>.say             # Print each on a newline

Haskell, 170 163 bytes
Edit: -7 bytes thanks to @Ørjan Johansen
m=<<"Mc Ul WeWg YdTgZa ZcSdZcX cRdZcW cSdYcW cSdYcW cTdXcW cTdXcW cUkW cUkW cVdVcW cVcUcW ZdYdPa YhRc Un U "
m ' '="###\n"
m c=(' '<$['Z','Y'..c])++('#'<$['a'..c])

Try it online!
Spaces are encoded as uppercase characters (length: Z down to char), hash signs as lowercase characters (length: a to char) and the last three # of each line plus newline as a space. Function m decodes it.

I think you can save some by letting space encode "###\n".

J, 130 128 bytes
echo' #'{~18 27$;(_243{.2#.inv 92x#._32+a.i.])&>'!TYPW.ajz i8hIhXl''3lOH8GvV.C2Z{r/=,G';'"a*2ZDxRplkh2tzRakz.?ZwVmeOT6L^lFB^eyT'

Try it online!
Initial solution
J, 164 bytes
echo' #'{~18 27$,#:849239965469633263905532594449192007713271791872263657753301928240007 12380965417202148347902847903517734495157419855048834759608223758433386496x

Try it online!

PHP, 286 212 209 208 bytes
<?php foreach(str_split('000680018y4g04uj1s0iql6k0yz98u1xxu2v1xyhs71xyhs71xzt6v1xzt6v1y2ruv1y2ruv1y7pmv1y70cn121jq60jwdto018y5s13bwg',6)as $i)echo str_replace(0,' ',str_pad(base_convert($i,36,2),27,0,0))."
";

Try it online!

Perl 5, 181 bytes
say+(sprintf"%28b",oct"0x$_")=~y/10/# /r for"0003f0003fff800f87fe03c07f78700f71ce00f70ee01e70ee01e70ee03c70ee03c70ee07ff0ee07ff0ee0f070ee0e070e79e003c3fc01f803fffe00380000"=~/.{7}/g

Try it online!

MATLAB : 144 Bytes
reshape(repelem([repmat(' #',1,44),' '],'NFMOJEDJFDGGADCCHDACCCACIDACDFHDBCDFHDBCDFGDCCDFGDCCDFFKDFFKDFEDECDFECFCDCADBDKDCHIFHQJCR'-64),27,[])'

Try it online! (Technically in Octave)
Explanation:
This uses the same strategy as digEmAll in R, just with MATLAB syntax. The main difference is that MATLAB has automatic conversion from characters to integers.

C# (.NET Core), 199 bytes
_=>{var r="";for(int i=0,j,k=0;i<88;i++)for(j=0;j++<"0(/1,'&,(&))#&%%*&#%%%#%+&#%&(*&$%&(*&$%&()&%%&()&%%&((-&((-&('&'%&('%(%&%#&$&-&%*+(*3,%"[i]-34;){r+=i%2<1?' ':'#';if(++k%27<1)r+='\n';}return r;}

Try it online!
Uses the same approach as my solution to the tribute to Adam West.

190 bytes

Deadfish~, 726 723 bytes
-3 bytes thanks to @squid
{iii}ii{c}cccciccccccddd{dd}c{ii}iicccccci{c}cccccddd{dd}c{ii}iiccccicccccdcccci{c}ddd{dd}c{ii}iicciccccdcccccccicccccccdciccccddd{dd}c{ii}iicicccdcccccccciccccdcicccdcccicccddd{dd}c{ii}iiicccdccccccccciccccdcicccdccccicccddd{dd}c{ii}iiicccdcccccccciccccdccicccdccccicccddd{dd}c{ii}iiicccdcccccccciccccdccicccdccccicccddd{dd}c{ii}iiicccdccccccciccccdcccicccdccccicccddd{dd}c{ii}iiicccdccccccciccccdcccicccdccccicccddd{dd}c{ii}iiicccdcccccci{c}cdccccicccddd{dd}c{ii}iiicccdcccccci{c}cdccccicccddd{dd}c{ii}iiicccdccccciccccdcccccicccdccccicccddd{dd}c{ii}iiicccdcccccicccdccccccicccdccccicccddd{dd}c{ii}iiciccccdcciccccd{c}ciccccddd{dd}c{ii}iicciccccccccdccccccccciccccccddd{dd}c{ii}iicccccci{c}cccccccddd{dd}c{ii}iicccccciccc

Try it online!

Having never seen/read anything Marvel and only relying on spoilers, it seems that Thanos is the best.

-3 bytes

Turing Machine But Way Worse - 16913 bytes
0 0 0 1 1 0 0
0 1 0 1 2 0 0
0 2 1 0 3 1 0
0 3 0 1 0 1 0
1 0 1 1 4 1 0
0 4 0 1 5 1 0
0 5 0 0 6 1 0
0 6 0 1 7 1 0
0 7 0 0 8 1 0
0 8 0 1 9 1 0
0 9 0 0 10 1 0
0 10 0 1 11 1 0
0 11 0 0 12 1 0
0 12 0 1 13 1 0
0 13 0 0 14 1 0
0 14 0 1 15 1 0
0 15 0 1 16 0 0
0 16 0 1 17 0 0
0 17 1 1 18 0 0
0 18 1 0 1 1 0
1 1 1 0 19 1 0
0 19 0 0 20 1 0
0 20 0 0 21 1 0
0 21 0 1 22 1 0
0 22 0 0 23 1 0
0 23 0 0 2 0 0
1 2 0 0 24 0 0
0 24 0 1 25 0 0
0 25 0 1 26 0 0
0 26 0 1 27 0 0
0 27 1 1 28 0 0
0 28 0 1 3 0 0
1 3 1 1 4 0 0
1 4 0 0 5 1 0
1 5 0 0 29 0 0
0 29 0 0 6 0 0
1 6 0 0 30 0 0
0 30 0 0 31 0 0
0 31 1 0 32 1 0
0 32 0 1 7 1 0
1 7 1 1 33 1 0
0 33 0 1 34 1 0
0 34 0 0 35 1 0
0 35 0 1 36 1 0
0 36 0 1 37 0 0
0 37 0 1 38 0 0
0 38 1 1 39 0 0
0 39 1 0 8 1 0
1 8 1 0 40 1 0
0 40 0 0 41 1 0
0 41 0 0 42 1 0
0 42 0 1 43 1 0
0 43 0 0 44 1 0
0 44 0 1 45 1 0
0 45 0 0 46 1 0
0 46 0 1 47 1 0
0 47 0 0 48 1 0
0 48 0 1 49 1 0
0 49 0 0 50 1 0
0 50 0 1 51 1 0
0 51 0 0 52 1 0
0 52 0 1 53 1 0
0 53 1 1 54 0 0
0 54 0 1 9 0 0
1 9 1 1 10 0 0
1 10 0 0 11 0 0
1 11 1 0 55 0 0
0 55 0 0 12 0 0
1 12 1 0 56 0 0
0 56 0 0 13 0 0
1 13 0 0 57 1 0
0 57 0 1 58 0 0
0 58 1 0 59 0 0
0 59 0 1 14 0 0
1 14 1 1 60 0 0
0 60 0 1 15 0 0
1 15 0 1 61 0 0
0 61 0 1 16 0 0
1 16 0 0 62 1 0
0 62 0 0 63 1 0
0 63 0 0 64 1 0
0 64 0 1 65 1 0
0 65 0 1 66 0 0
0 66 0 1 67 0 0
0 67 1 1 68 0 0
0 68 1 0 17 1 0
1 17 1 0 69 1 0
0 69 0 0 70 1 0
0 70 0 0 71 1 0
0 71 0 1 72 1 0
0 72 0 1 73 0 0
0 73 0 1 18 0 0
1 18 0 1 19 0 0
1 19 0 0 74 1 0
0 74 0 0 75 1 0
0 75 0 0 76 1 0
0 76 0 0 77 1 0
0 77 0 1 78 0 0
0 78 0 1 79 0 0
0 79 0 1 80 0 0
0 80 1 1 81 0 0
0 81 1 0 20 1 0
1 20 1 0 82 1 0
0 82 0 0 83 1 0
0 83 0 0 84 1 0
0 84 0 1 85 1 0
0 85 0 0 86 1 0
0 86 0 1 87 1 0
0 87 0 0 88 1 0
0 88 0 1 89 1 0
0 89 0 0 90 1 0
0 90 0 0 21 0 0
1 21 0 0 91 0 0
0 91 0 1 92 0 0
0 92 0 1 93 0 0
0 93 0 1 94 0 0
0 94 1 1 95 0 0
0 95 0 1 22 0 0
1 22 1 1 23 0 0
1 23 0 0 24 1 0
1 24 0 0 96 0 0
0 96 0 0 25 0 0
1 25 0 0 97 0 0
0 97 0 0 98 0 0
0 98 1 0 99 1 0
0 99 0 1 26 1 0
1 26 1 1 100 0 0
0 100 0 1 101 0 0
0 101 0 1 102 0 0
0 102 0 1 103 0 0
0 103 1 1 104 0 0
0 104 1 0 27 1 0
1 27 1 0 105 1 0
0 105 0 0 106 1 0
0 106 0 0 107 1 0
0 107 0 1 108 0 0
0 108 0 1 109 0 0
0 109 0 1 28 0 0
1 28 0 1 29 0 0
1 29 0 0 110 1 0
0 110 0 0 111 1 0
0 111 0 0 112 1 0
0 112 0 0 113 1 0
0 113 0 1 114 1 0
0 114 0 0 115 1 0
0 115 0 1 116 1 0
0 116 0 1 117 0 0
0 117 0 1 118 0 0
0 118 1 1 119 0 0
0 119 1 0 30 1 0
1 30 1 0 120 1 0
0 120 0 0 121 1 0
0 121 0 0 122 1 0
0 122 0 1 123 1 0
0 123 0 0 124 1 0
0 124 0 1 125 1 0
0 125 0 1 126 0 0
0 126 0 1 31 0 0
1 31 0 1 32 0 0
1 32 0 0 127 1 0
0 127 1 1 128 0 0
0 128 1 0 33 1 0
1 33 1 0 129 1 0
0 129 0 0 130 1 0
0 130 0 0 131 1 0
0 131 0 0 34 0 0
1 34 0 0 132 0 0
0 132 0 1 133 0 0
0 133 0 1 134 0 0
0 134 0 1 135 0 0
0 135 1 1 136 0 0
0 136 0 1 35 0 0
1 35 1 1 36 0 0
1 36 0 0 37 1 0
1 37 0 0 137 0 0
0 137 0 0 38 0 0
1 38 0 0 138 0 0
0 138 0 0 139 0 0
0 139 1 0 140 1 0
0 140 0 1 39 0 0
1 39 1 1 141 0 0
0 141 0 1 142 0 0
0 142 0 1 143 0 0
0 143 0 1 144 0 0
0 144 1 1 145 0 0
0 145 1 0 40 1 0
1 40 1 0 146 1 0
0 146 0 0 147 1 0
0 147 0 1 148 0 0
0 148 0 1 41 0 0
1 41 0 1 42 0 0
1 42 0 0 149 1 0
0 149 0 0 150 1 0
0 150 0 0 151 1 0
0 151 0 0 152 1 0
0 152 0 1 153 1 0
0 153 0 0 154 1 0
0 154 0 1 155 1 0
0 155 0 0 156 1 0
0 156 0 1 157 0 0
0 157 0 1 158 0 0
0 158 0 1 159 0 0
0 159 1 1 160 0 0
0 160 1 0 43 1 0
1 43 1 0 161 1 0
0 161 0 0 162 1 0
0 162 0 0 163 1 0
0 163 0 1 164 0 0
0 164 0 1 165 0 0
0 165 0 1 44 0 0
1 44 0 1 45 0 0
1 45 0 0 166 1 0
0 166 1 1 167 0 0
0 167 1 0 46 1 0
1 46 1 0 168 1 0
0 168 0 0 169 1 0
0 169 0 1 170 0 0
0 170 0 1 47 0 0
1 47 0 1 48 0 0
1 48 0 0 171 1 0
0 171 0 0 172 1 0
0 172 0 0 173 1 0
0 173 0 1 174 0 0
0 174 0 1 175 0 0
0 175 1 1 176 0 0
0 176 1 0 49 1 0
1 49 1 0 177 1 0
0 177 0 0 178 1 0
0 178 1 1 179 0 0
0 179 0 1 50 0 0
1 50 1 1 51 0 0
1 51 0 0 52 0 0
1 52 1 0 180 0 0
0 180 0 0 53 0 0
1 53 1 0 181 0 0
0 181 0 0 54 0 0
1 54 0 0 182 1 0
0 182 0 1 183 0 0
0 183 1 0 184 0 0
0 184 0 1 55 0 0
1 55 1 1 185 0 0
0 185 0 1 56 0 0
1 56 0 1 186 0 0
0 186 0 1 57 0 0
1 57 1 1 187 0 0
0 187 1 0 58 1 0
1 58 1 0 188 1 0
0 188 0 0 189 1 0
0 189 0 1 190 0 0
0 190 0 1 59 0 0
1 59 0 1 60 0 0
1 60 0 0 191 1 0
0 191 0 0 192 1 0
0 192 0 0 193 1 0
0 193 0 0 194 1 0
0 194 0 1 195 1 0
0 195 0 0 196 1 0
0 196 0 1 197 1 0
0 197 0 0 198 1 0
0 198 0 1 199 1 0
0 199 0 1 200 0 0
0 200 0 1 201 0 0
0 201 1 1 202 0 0
0 202 1 0 61 1 0
1 61 1 0 203 1 0
0 203 0 0 204 1 0
0 204 0 0 205 1 0
0 205 0 1 206 0 0
0 206 0 1 207 0 0
0 207 0 1 62 0 0
1 62 0 1 63 0 0
1 63 0 0 208 1 0
0 208 1 1 209 0 0
0 209 1 0 64 1 0
1 64 1 0 210 1 0
0 210 0 0 211 1 0
0 211 0 1 212 0 0
0 212 0 1 65 0 0
1 65 0 1 66 0 0
1 66 0 0 213 1 0
0 213 0 0 214 1 0
0 214 0 0 215 1 0
0 215 0 0 216 1 0
0 216 0 1 217 0 0
0 217 0 1 218 0 0
0 218 0 1 219 0 0
0 219 1 1 220 0 0
0 220 1 0 67 1 0
1 67 1 0 221 1 0
0 221 0 0 222 1 0
0 222 1 1 223 0 0
0 223 0 1 68 0 0
1 68 1 1 69 0 0
1 69 0 0 70 0 0
1 70 1 0 224 0 0
0 224 0 0 71 0 0
1 71 1 0 225 0 0
0 225 0 0 72 0 0
1 72 0 0 226 1 0
0 226 0 1 227 0 0
0 227 1 0 228 0 0
0 228 0 1 73 0 0
1 73 1 1 229 0 0
0 229 0 1 74 0 0
1 74 0 1 230 0 0
0 230 0 1 75 0 0
1 75 1 1 231 0 0
0 231 1 0 76 1 0
1 76 1 0 232 1 0
0 232 0 0 233 1 0
0 233 0 1 234 0 0
0 234 0 1 77 0 0
1 77 0 1 78 0 0
1 78 0 0 235 1 0
0 235 0 0 236 1 0
0 236 0 0 237 1 0
0 237 0 0 238 1 0
0 238 0 1 239 1 0
0 239 0 0 240 1 0
0 240 0 1 241 1 0
0 241 0 0 242 1 0
0 242 0 1 243 0 0
0 243 0 1 244 0 0
0 244 0 1 245 0 0
0 245 1 1 246 0 0
0 246 1 0 79 1 0
1 79 1 0 247 1 0
0 247 0 0 248 1 0
0 248 0 0 249 1 0
0 249 0 1 250 0 0
0 250 0 1 251 0 0
0 251 0 1 80 0 0
1 80 0 1 81 0 0
1 81 0 0 252 1 0
0 252 0 0 253 1 0
0 253 0 1 254 0 0
0 254 1 1 255 0 0
0 255 1 0 82 1 0
1 82 1 0 256 1 0
0 256 0 0 257 1 0
0 257 0 1 258 0 0
0 258 0 1 83 0 0
1 83 0 1 84 0 0
1 84 0 0 259 1 0
0 259 0 0 260 1 0
0 260 0 0 261 1 0
0 261 0 0 262 1 0
0 262 0 1 263 0 0
0 263 0 1 264 0 0
0 264 0 1 265 0 0
0 265 1 1 266 0 0
0 266 1 0 85 1 0
1 85 1 0 267 1 0
0 267 0 0 268 1 0
0 268 1 1 269 0 0
0 269 0 1 86 0 0
1 86 1 1 87 0 0
1 87 0 0 88 0 0
1 88 1 0 270 0 0
0 270 0 0 89 0 0
1 89 1 0 271 0 0
0 271 0 0 90 0 0
1 90 0 0 272 1 0
0 272 0 1 273 0 0
0 273 1 0 274 0 0
0 274 0 1 91 0 0
1 91 1 1 275 0 0
0 275 0 1 92 0 0
1 92 0 1 276 0 0
0 276 0 1 93 0 0
1 93 1 1 277 0 0
0 277 1 0 94 1 0
1 94 1 0 278 1 0
0 278 0 0 279 1 0
0 279 0 1 280 0 0
0 280 0 1 95 0 0
1 95 0 1 96 0 0
1 96 0 0 281 1 0
0 281 0 0 282 1 0
0 282 0 0 283 1 0
0 283 0 0 284 1 0
0 284 0 1 285 1 0
0 285 0 0 286 1 0
0 286 0 1 287 1 0
0 287 0 0 288 1 0
0 288 0 1 289 0 0
0 289 0 1 290 0 0
0 290 0 1 291 0 0
0 291 1 1 292 0 0
0 292 1 0 97 1 0
1 97 1 0 293 1 0
0 293 0 0 294 1 0
0 294 0 0 295 1 0
0 295 0 1 296 0 0
0 296 0 1 297 0 0
0 297 0 1 98 0 0
1 98 0 1 99 0 0
1 99 0 0 298 1 0
0 298 0 0 299 1 0
0 299 0 1 300 0 0
0 300 1 1 301 0 0
0 301 1 0 100 1 0
1 100 1 0 302 1 0
0 302 0 0 303 1 0
0 303 0 1 304 0 0
0 304 0 1 101 0 0
1 101 0 1 102 0 0
1 102 0 0 305 1 0
0 305 0 0 306 1 0
0 306 0 0 307 1 0
0 307 0 0 308 1 0
0 308 0 1 309 0 0
0 309 0 1 310 0 0
0 310 0 1 311 0 0
0 311 1 1 312 0 0
0 312 1 0 103 1 0
1 103 1 0 313 1 0
0 313 0 0 314 1 0
0 314 1 1 315 0 0
0 315 0 1 104 0 0
1 104 1 1 105 0 0
1 105 0 0 106 0 0
1 106 1 0 316 0 0
0 316 0 0 107 0 0
1 107 1 0 317 0 0
0 317 0 0 108 0 0
1 108 0 0 318 1 0
0 318 0 1 319 0 0
0 319 1 0 320 0 0
0 320 0 1 109 0 0
1 109 1 1 321 0 0
0 321 0 1 110 0 0
1 110 0 1 322 0 0
0 322 0 1 111 0 0
1 111 1 1 323 0 0
0 323 1 0 112 1 0
1 112 1 0 324 1 0
0 324 0 0 325 1 0
0 325 0 1 326 0 0
0 326 0 1 113 0 0
1 113 0 1 114 0 0
1 114 0 0 327 1 0
0 327 0 0 328 1 0
0 328 0 0 329 1 0
0 329 0 0 330 1 0
0 330 0 1 331 1 0
0 331 0 0 332 1 0
0 332 0 1 333 1 0
0 333 0 1 334 0 0
0 334 0 1 335 0 0
0 335 1 1 336 0 0
0 336 1 0 115 1 0
1 115 1 0 337 1 0
0 337 0 0 338 1 0
0 338 0 0 339 1 0
0 339 0 1 340 0 0
0 340 0 1 341 0 0
0 341 0 1 116 0 0
1 116 0 1 117 0 0
1 117 0 0 342 1 0
0 342 0 0 343 1 0
0 343 0 0 344 1 0
0 344 0 1 345 0 0
0 345 0 1 346 0 0
0 346 1 1 347 0 0
0 347 1 0 118 1 0
1 118 1 0 348 1 0
0 348 0 0 349 1 0
0 349 0 1 350 0 0
0 350 0 1 119 0 0
1 119 0 1 120 0 0
1 120 0 0 351 1 0
0 351 0 0 352 1 0
0 352 0 0 353 1 0
0 353 0 0 354 1 0
0 354 0 1 355 0 0
0 355 0 1 356 0 0
0 356 0 1 357 0 0
0 357 1 1 358 0 0
0 358 1 0 121 1 0
1 121 1 0 359 1 0
0 359 0 0 360 1 0
0 360 1 1 361 0 0
0 361 0 1 122 0 0
1 122 1 1 123 0 0
1 123 0 0 124 0 0
1 124 1 0 362 0 0
0 362 0 0 125 0 0
1 125 1 0 363 0 0
0 363 0 0 126 0 0
1 126 0 0 364 1 0
0 364 0 1 365 0 0
0 365 1 0 366 0 0
0 366 0 1 127 0 0
1 127 1 1 367 0 0
0 367 0 1 128 0 0
1 128 0 1 368 0 0
0 368 0 1 129 0 0
1 129 1 1 369 0 0
0 369 1 0 130 1 0
1 130 1 0 370 1 0
0 370 0 0 371 1 0
0 371 0 1 372 0 0
0 372 0 1 131 0 0
1 131 0 1 132 0 0
1 132 0 0 373 1 0
0 373 0 0 374 1 0
0 374 0 0 375 1 0
0 375 0 0 376 1 0
0 376 0 1 377 1 0
0 377 0 0 378 1 0
0 378 0 1 379 1 0
0 379 0 1 380 0 0
0 380 0 1 381 0 0
0 381 1 1 382 0 0
0 382 1 0 133 1 0
1 133 1 0 383 1 0
0 383 0 0 384 1 0
0 384 0 0 385 1 0
0 385 0 1 386 0 0
0 386 0 1 387 0 0
0 387 0 1 134 0 0
1 134 0 1 135 0 0
1 135 0 0 388 1 0
0 388 0 0 389 1 0
0 389 0 0 390 1 0
0 390 0 1 391 0 0
0 391 0 1 392 0 0
0 392 1 1 393 0 0
0 393 1 0 136 1 0
1 136 1 0 394 1 0
0 394 0 0 395 1 0
0 395 0 1 396 0 0
0 396 0 1 137 0 0
1 137 0 1 138 0 0
1 138 0 0 397 1 0
0 397 0 0 398 1 0
0 398 0 0 399 1 0
0 399 0 0 400 1 0
0 400 0 1 401 0 0
0 401 0 1 402 0 0
0 402 0 1 403 0 0
0 403 1 1 404 0 0
0 404 1 0 139 1 0
1 139 1 0 405 1 0
0 405 0 0 406 1 0
0 406 1 1 407 0 0
0 407 0 1 140 0 0
1 140 1 1 141 0 0
1 141 0 0 142 0 0
1 142 1 0 408 0 0
0 408 0 0 143 0 0
1 143 1 0 409 0 0
0 409 0 0 144 0 0
1 144 0 0 410 1 0
0 410 0 1 411 0 0
0 411 1 0 412 0 0
0 412 0 1 145 0 0
1 145 1 1 413 0 0
0 413 0 1 146 0 0
1 146 0 1 414 0 0
0 414 0 1 147 0 0
1 147 1 1 415 0 0
0 415 1 0 148 1 0
1 148 1 0 416 1 0
0 416 0 0 417 1 0
0 417 0 1 418 0 0
0 418 0 1 149 0 0
1 149 0 1 150 0 0
1 150 0 0 419 1 0
0 419 0 0 420 1 0
0 420 0 0 421 1 0
0 421 0 0 422 1 0
0 422 0 1 423 1 0
0 423 0 0 424 1 0
0 424 0 1 425 0 0
0 425 0 1 426 0 0
0 426 0 1 427 0 0
0 427 1 1 428 0 0
0 428 1 0 151 1 0
1 151 1 0 429 1 0
0 429 0 0 430 1 0
0 430 0 0 431 1 0
0 431 0 1 432 1 0
0 432 0 0 433 1 0
0 433 0 1 434 1 0
0 434 0 0 435 1 0
0 435 0 1 436 1 0
0 436 0 0 437 1 0
0 437 0 1 438 1 0
0 438 0 1 439 0 0
0 439 0 1 152 0 0
1 152 0 1 153 0 0
1 153 0 0 440 1 0
0 440 0 0 441 1 0
0 441 0 0 442 1 0
0 442 0 0 443 1 0
0 443 0 1 444 0 0
0 444 0 1 445 0 0
0 445 0 1 446 0 0
0 446 1 1 447 0 0
0 447 1 0 154 1 0
1 154 1 0 448 1 0
0 448 0 0 449 1 0
0 449 1 1 450 0 0
0 450 0 1 155 0 0
1 155 1 1 156 0 0
1 156 0 0 157 0 0
1 157 1 0 451 0 0
0 451 0 0 158 0 0
1 158 1 0 452 0 0
0 452 0 0 159 0 0
1 159 0 0 453 1 0
0 453 0 1 454 0 0
0 454 1 0 455 0 0
0 455 0 1 160 0 0
1 160 1 1 456 0 0
0 456 0 1 161 0 0
1 161 0 1 457 0 0
0 457 0 1 162 0 0
1 162 1 1 458 0 0
0 458 1 0 163 1 0
1 163 1 0 459 1 0
0 459 0 0 460 1 0
0 460 0 1 461 0 0
0 461 0 1 164 0 0
1 164 0 1 165 0 0
1 165 0 0 462 1 0
0 462 0 0 463 1 0
0 463 0 0 464 1 0
0 464 0 0 465 1 0
0 465 0 1 466 1 0
0 466 0 0 467 1 0
0 467 0 1 468 0 0
0 468 0 1 469 0 0
0 469 0 1 470 0 0
0 470 1 1 471 0 0
0 471 1 0 166 1 0
1 166 1 0 472 1 0
0 472 0 0 473 1 0
0 473 0 0 474 1 0
0 474 0 1 475 1 0
0 475 0 0 476 1 0
0 476 0 1 477 1 0
0 477 0 0 478 1 0
0 478 0 1 479 1 0
0 479 0 0 480 1 0
0 480 0 1 481 1 0
0 481 0 1 482 0 0
0 482 0 1 167 0 0
1 167 0 1 168 0 0
1 168 0 0 483 1 0
0 483 0 0 484 1 0
0 484 0 0 485 1 0
0 485 0 0 486 1 0
0 486 0 1 487 0 0
0 487 0 1 488 0 0
0 488 0 1 489 0 0
0 489 1 1 490 0 0
0 490 1 0 169 1 0
1 169 1 0 491 1 0
0 491 0 0 492 1 0
0 492 1 1 493 0 0
0 493 0 1 170 0 0
1 170 1 1 171 0 0
1 171 0 0 172 0 0
1 172 1 0 494 0 0
0 494 0 0 173 0 0
1 173 1 0 495 0 0
0 495 0 0 174 0 0
1 174 0 0 496 1 0
0 496 0 1 497 0 0
0 497 1 0 498 0 0
0 498 0 1 175 0 0
1 175 1 1 499 0 0
0 499 0 1 176 0 0
1 176 0 1 500 0 0
0 500 0 1 177 0 0
1 177 1 1 501 0 0
0 501 1 0 178 1 0
1 178 1 0 502 1 0
0 502 0 0 503 1 0
0 503 0 1 504 0 0
0 504 0 1 179 0 0
1 179 0 1 180 0 0
1 180 0 0 505 1 0
0 505 0 0 506 1 0
0 506 0 0 507 1 0
0 507 0 0 508 1 0
0 508 0 1 509 1 0
0 509 0 1 510 0 0
0 510 0 1 511 0 0
0 511 1 1 512 0 0
0 512 1 0 181 1 0
1 181 1 0 513 1 0
0 513 0 0 514 1 0
0 514 0 0 515 1 0
0 515 0 1 516 0 0
0 516 0 1 517 0 0
0 517 0 1 182 0 0
1 182 0 1 183 0 0
1 183 0 0 518 1 0
0 518 0 0 519 1 0
0 519 0 0 520 1 0
0 520 0 0 521 1 0
0 521 0 1 522 1 0
0 522 0 1 523 0 0
0 523 0 1 524 0 0
0 524 1 1 525 0 0
0 525 1 0 184 1 0
1 184 1 0 526 1 0
0 526 0 0 527 1 0
0 527 0 1 528 0 0
0 528 0 1 185 0 0
1 185 0 1 186 0 0
1 186 0 0 529 1 0
0 529 0 0 530 1 0
0 530 0 0 531 1 0
0 531 0 0 532 1 0
0 532 0 1 533 0 0
0 533 0 1 534 0 0
0 534 0 1 535 0 0
0 535 1 1 536 0 0
0 536 1 0 187 1 0
1 187 1 0 537 1 0
0 537 0 0 538 1 0
0 538 1 1 539 0 0
0 539 0 1 188 0 0
1 188 1 1 189 0 0
1 189 0 0 190 0 0
1 190 1 0 540 0 0
0 540 0 0 191 0 0
1 191 1 0 541 0 0
0 541 0 0 192 0 0
1 192 0 0 542 1 0
0 542 0 1 543 0 0
0 543 1 0 544 0 0
0 544 0 1 193 0 0
1 193 1 1 545 0 0
0 545 0 1 194 0 0
1 194 0 1 546 0 0
0 546 0 1 195 0 0
1 195 1 1 547 0 0
0 547 1 0 196 1 0
1 196 1 0 548 1 0
0 548 0 0 549 1 0
0 549 0 1 550 0 0
0 550 0 1 197 0 0
1 197 0 1 198 0 0
1 198 0 0 551 1 0
0 551 0 0 552 1 0
0 552 0 0 553 1 0
0 553 0 0 554 1 0
0 554 0 1 555 1 0
0 555 0 1 556 0 0
0 556 0 1 557 0 0
0 557 1 1 558 0 0
0 558 1 0 199 1 0
1 199 1 0 559 1 0
0 559 0 0 560 1 0
0 560 0 1 561 0 0
0 561 0 1 200 0 0
1 200 0 1 201 0 0
1 201 0 0 562 1 0
0 562 0 0 563 1 0
0 563 0 0 564 1 0
0 564 0 0 565 1 0
0 565 0 1 566 1 0
0 566 0 0 567 1 0
0 567 0 1 568 0 0
0 568 0 1 569 0 0
0 569 0 1 570 0 0
0 570 1 1 571 0 0
0 571 1 0 202 1 0
1 202 1 0 572 1 0
0 572 0 0 573 1 0
0 573 0 1 574 0 0
0 574 0 1 203 0 0
1 203 0 1 204 0 0
1 204 0 0 575 1 0
0 575 0 0 576 1 0
0 576 0 0 577 1 0
0 577 0 0 578 1 0
0 578 0 1 579 0 0
0 579 0 1 580 0 0
0 580 0 1 581 0 0
0 581 1 1 582 0 0
0 582 1 0 205 1 0
1 205 1 0 583 1 0
0 583 0 0 584 1 0
0 584 1 1 585 0 0
0 585 0 1 206 0 0
1 206 1 1 207 0 0
1 207 0 0 208 0 0
1 208 1 0 586 0 0
0 586 0 0 209 0 0
1 209 1 0 587 0 0
0 587 0 0 210 0 0
1 210 0 0 588 1 0
0 588 0 1 589 0 0
0 589 1 0 590 0 0
0 590 0 1 211 0 0
1 211 1 1 591 0 0
0 591 0 1 212 0 0
1 212 0 1 592 0 0
0 592 0 1 213 0 0
1 213 0 0 593 1 0
0 593 0 1 594 0 0
0 594 1 1 595 0 0
0 595 1 0 214 1 0
1 214 1 0 596 1 0
0 596 0 0 597 1 0
0 597 0 0 598 1 0
0 598 0 1 599 0 0
0 599 0 1 600 0 0
0 600 0 1 215 0 0
1 215 0 1 216 0 0
1 216 0 0 601 1 0
0 601 0 0 602 1 0
0 602 0 1 603 0 0
0 603 1 1 604 0 0
0 604 1 0 217 1 0
1 217 1 0 605 1 0
0 605 0 0 606 1 0
0 606 0 0 607 1 0
0 607 0 1 608 0 0
0 608 0 1 609 0 0
0 609 0 1 218 0 0
1 218 0 1 219 0 0
1 219 0 0 610 1 0
0 610 0 0 611 1 0
0 611 0 0 612 1 0
0 612 0 0 613 1 0
0 613 0 1 614 1 0
0 614 0 0 615 1 0
0 615 0 1 616 1 0
0 616 0 0 617 1 0
0 617 0 1 618 1 0
0 618 0 0 619 1 0
0 619 0 1 620 1 0
0 620 0 1 621 0 0
0 621 0 1 622 0 0
0 622 1 1 623 0 0
0 623 1 0 220 1 0
1 220 1 0 624 1 0
0 624 0 0 625 1 0
0 625 0 0 626 1 0
0 626 0 0 221 0 0
1 221 0 0 627 0 0
0 627 0 1 628 0 0
0 628 0 1 629 0 0
0 629 0 1 630 0 0
0 630 1 1 631 0 0
0 631 0 1 222 0 0
1 222 1 1 223 0 0
1 223 0 0 224 1 0
1 224 0 0 632 0 0
0 632 0 0 225 0 0
1 225 0 0 633 0 0
0 633 0 0 634 0 0
0 634 1 0 635 1 0
0 635 0 1 226 1 0
1 226 1 1 636 0 0
0 636 0 1 637 0 0
0 637 0 1 638 0 0
0 638 0 1 639 0 0
0 639 1 1 640 0 0
0 640 1 0 227 1 0
1 227 1 0 641 1 0
0 641 0 0 642 1 0
0 642 0 0 643 1 0
0 643 0 1 644 1 0
0 644 0 0 645 1 0
0 645 0 1 646 1 0
0 646 0 0 647 1 0
0 647 0 1 648 0 0
0 648 0 1 649 0 0
0 649 0 1 228 0 0
1 228 0 1 229 0 0
1 229 0 0 650 1 0
0 650 0 0 651 1 0
0 651 0 0 652 1 0
0 652 0 0 653 1 0
0 653 0 1 654 1 0
0 654 0 0 655 1 0
0 655 0 1 656 1 0
0 656 0 0 657 1 0
0 657 0 1 658 1 0
0 658 0 1 659 0 0
0 659 0 1 660 0 0
0 660 1 1 661 0 0
0 661 1 0 230 1 0
1 230 1 0 662 1 0
0 662 0 0 663 1 0
0 663 0 0 664 1 0
0 664 0 1 665 1 0
0 665 0 0 666 1 0
0 666 0 0 231 0 0
1 231 0 0 667 0 0
0 667 0 1 668 0 0
0 668 0 1 669 0 0
0 669 0 1 670 0 0
0 670 1 1 671 0 0
0 671 0 1 232 0 0
1 232 1 1 233 0 0
1 233 0 0 234 1 0
1 234 0 0 672 0 0
0 672 0 0 235 0 0
1 235 0 0 673 0 0
0 673 0 0 674 0 0
0 674 1 0 675 1 0
0 675 0 1 236 1 0
1 236 1 1 676 1 0
0 676 0 1 677 1 0
0 677 0 0 678 1 0
0 678 0 1 679 1 0
0 679 0 1 680 0 0
0 680 0 1 681 0 0
0 681 1 1 682 0 0
0 682 1 0 237 1 0
1 237 1 0 683 1 0
0 683 0 0 684 1 0
0 684 0 0 685 1 0
0 685 0 1 686 1 0
0 686 0 0 687 1 0
0 687 0 1 688 1 0
0 688 0 0 689 1 0
0 689 0 1 690 1 0
0 690 0 0 691 1 0
0 691 0 1 692 1 0
0 692 0 0 693 1 0
0 693 0 1 694 1 0
0 694 0 0 695 1 0
0 695 0 1 696 1 0
0 696 0 0 697 1 0
0 697 0 1 698 1 0
0 698 1 1 699 0 0
0 699 0 1 238 0 0
1 238 1 1 239 0 0
1 239 0 0 240 0 0
1 240 1 0 700 0 0
0 700 0 0 241 0 0
1 241 1 0 701 0 0
0 701 0 0 242 0 0
1 242 0 0 702 1 0
0 702 0 1 703 0 0
0 703 1 0 704 0 0
0 704 0 1 243 0 0
1 243 1 1 705 0 0
0 705 0 1 244 0 0
1 244 0 1 706 0 0
0 706 0 1 245 0 0
1 245 0 0 707 1 0
0 707 0 0 708 1 0
0 708 0 0 709 1 0
0 709 0 1 710 1 0
0 710 0 0 711 1 0
0 711 0 1 712 1 0
0 712 0 1 713 0 0
0 713 0 1 714 0 0
0 714 1 1 715 0 0
0 715 1 0 246 1 0
1 246 1 0 716 1 0
0 716 0 0 717 1 1

Made with ASCII_only's program generator

deflate, 79 bytes
eJyVkcsJADAIQ++ZIpD9dyxUqrGUgjlpHvglXdqCJymk1yEiaRXEIOXzuBHCiKObReUxUzYaMdt2wmTBg/FmNXndgLRbNvL7ifsLfMw6iQ==

You appear to have posted two answers in the same language. If you make an improvement to your submission it is better to edit your existing answer. Additionally, could you provide a link to the deflate language, as this just looks like a base64 string

I don't think deflate counts as a programming language (although I could be wrong as I don't participate on PPCG).

This is not DEFLATE, but zlib, which is DEFLATE plus a 2 byte header and a 4 byte checksum. By stripping those, you can use the Bubblegum interpreter.

@NobodyNada deflate is not a programming language but we do not require that submissions be in programming languages.

Brainf***, 656 652 605 bytes
++[+++[<+>->>+>->-<<<<]>-]>..............>......>+.<<......>...............>.<<....>.....<....>..........>.<<..>....<.......>.......<.>....>.<<.>...<........>....<.>...<...>...>.<...<.........>....<.>...<....>...>.<...<........>....<..>...<....>...>.<...<........>....<..>...<....>...>.<...<.......>....<...>...<....>...>.<...<.......>....<...>...<....>...>.<...<......>...........<....>...>.<...<......>...........<....>...>.<...<.....>....<.....>...<....>...>.<...<.....>...<......>...<....>...>.<<.>....<..>....<...........>....>.<<..>........<.........>......>.<<......>.................>.<<......>...

The loop at the start initiates the tape to
... 032  [035]  010 ...

Then the rest of the code outputs those characters.
(-47 bytes thanks to orthoplex)

A shorter initialization loop can save you 47 bytes: https://tio.run/##pZJdCoAgEIQPtOgJlrlI9FBBEEEPQee3n80a7eehFhTd@dB13HqsuqGdmj4EkUKWoQIHrJPTJUq4Ej6JfQvxqkmGCFMsrxliKg6JVLXVRoD0SMccDGIiR@6YeOdP5ij9H8OufSTIRLwxdB4zmryWvPT0D2cVemmBxw7ItRBm

T-SQL, 244 bytes
Golfed:
DECLARE @ varchar(max)='MfFoDEDjBDGGAcACHDACCc@CIDACDc@CHDBCDc@CHDBCDc@CGDCCDc@CGDCCDc@CFKDc@CFKDc@CEDECDc@CECFCDcADBDKdBHIfFqFC 'WHILE'!'<@
SET @=stuff(@,1,1,'')+replicate(char(35-charindex(' ',@)%2*3),ascii(@)%32)+left('
',ascii(@)/97)PRINT @

Ungolfed:
DECLARE
 @ varchar(max)='MfFoDEDjBDGGAcACHDACCc@CIDACDc@CHDBCDc@CHDBCDc@CGDCCDc@CGDCCDc@CFKDc@CFKDc@CEDECDc@CECFCDcADBDKdBHIfFqFC '

WHILE'!'<@
  SET
    @=stuff(@,1,1,'')+
    replicate(char(35-charindex(' ',@)%2*3),ascii(@)%32)+
    left('
',ascii(@)/97)
PRINT @

Try it online ungolfed version


text:
Calculate your Icy Tower Score
Do you know Icy Tower ? Here is a gameplay example of what i'm talking about
The game concept is simple : you play as Harold the Homeboy, and your goal is to jump from floors to floors to go as high as possible without falling and getting off-screen ( the camera goes higher following you or at a speed that gets faster over time, and does not go down ).
If you get off-screen ( fell or camera was too fast for you to keep up ), it's game over, and then you get a score.
Your task is to write a program/function/whatever that calculates the score based on a input.
How to calculate the score :
The formula is simple : \$Score = 10 * LastFloor +  Sum(ValidComboList.TotalFloorJumped^2)\$
What is a valid combo ?
You have to jump from floors to floors to go as high as possible. Sometimes, you will the to the floor \$F+1\$
But sometimes, if you go fast enough ( faster = higher jumps ), you will do a multi-floor jump, and skip some floors between. A combo is a sequence of multi-floors jump. To be considered as a multi-floor jump, you need to skip at least 1 floor, meaning you need to get to the floor \$F+x\$ where \$x >= 2\$
See that you always jump to \$x >= 2\$, jumps to lower floors with floors skipped between are not considered valid
A combo ends when :

You jump to the floor \$F+x\$ where \$(x < 0) | (x == 1)\$
You wait more than about 3 seconds on the same floor ( in the gameplay video, you can see on the left a "timing bar", and the combo ends if it gets empty )
You get off-screen ( falling or not jumping fast enough )

In this challenge, to simplify a bit, we will consider that, when the input indicates a "jump to the same floor \$F+0\$" means that the 3 second timeout is passed, so the two rules will be simplified in one :
"You jump to the floor \$F+x\$ where \$x<2\$
A valid combo ( a combo that will be used for the score calculation ) :

The number of multi-floor jumps \$N >= 2\$
The combo MUST NOT end with going off-screen. If you go off-screen, the combo is invalid and won't included in the score. Said in another way : The combo must be followed by a jump to another floor or by waiting about 3 seconds.

In this challenge, since we consider that jumping to the same floor is waiting 3 seconds, the rules to make a valid combo is "You must jump to another floor"
Since you need at least 2 multi-floor jumps to make a combo, the number of total floor jumped is higher than 4
The input
The input will be a "list" of integers ( or STDIN input ) which represents the sequence of floor jumped on. For example, the start to the video linked previously in the post will look like :
[5 4 5 10 12 15 17 18 19 20 23 24 25 28 29 30 31 34 35 36 37 34 35 36 37 38 39 40 43 48 45 46 50 55 54]

for the first floors. The start floor is ommited. This input end on floor 54 meaning he went off-screen just after that, without getting to another floor, so there's the game over ( this was not the case in the video since he went to the floor 232, so the array accurately representing the sequence would end with 232 at the end )
Here, with this input, you must output \$829\$, because :
\$Score = 10 * 54 + 12^2 + 8^2 + 9^2\$ Because the last floor Harold was on is the floor number 54, and he made 3 valid combos :

First combo of 4 multi-floor jumps with a total of  12 floors jumped in that combo
Second combo of 2 multi-floor jumps with a total of 8 floors jumped in that combo
The last combo of 2 multi-floor jumps with a total of 9 floors jumped in that combo

Test cases :
[] => Undefined Behavior
[5] => \$50\$
[4 0 5 6 8 10 10] => \$10*10 + 4^2 = 116\$ Correction applied
[4 0 5 6 6 6 6 8 10 10] => \$10*10 + 4^2 = 116\$ ( Here, Harold just waited 9 seconds. No combo to validate, but still a legitimate input ) Correction applied
[5 7 10 10 11 9 14 17 15 16] => \$10*16 + 10^2 + 8^2 = 324\$
[5 4 5 10 12 15 17 18 19 20 23 24 25 28 29 30 31 34 35 36 37 34 35 36 37 38 39 40 43 48 45 46 50 55 54] => \$10 * 54 + 12^2 + 8^2 + 9^2 = 829\$
[5 4 5 10 12 15 17 18 19 20 23 24 25 28 29 30 31 34 35 36 37 34 35 36 37 38 39 40 43 48 45 46 50 55 56] => \$10 * 54 + 12^2 + 8^2 + 9^2 = 849\$
[5 4 5 10 12 15 17 18 19 20 23 24 25 28 29 30 31 34 35 36 37 34 35 36 37 38 39 40 43 48 45 46 50 55 55] => \$10 * 55 + 12^2 + 8^2 + 9^2 = 839\$ ( harold waited 3 seconds to validate the combo )
[5 4 5 10 12 15 17 18 19 20 23 24 25 28 29 30 31 34 35 36 37 34 35 36 37 38 39 40 43 48 45 46 50 55] => \$10 * 55 + 12^2 + 8^2 = 758\$ ( because harold went off-screen without confirming the combo)
If you want, you can condsider that the input always starts with zero ( since the game start at floor 0 ), if this is the case, say it in your answer
Rules :

Input and output in any convenient way
Full program, or function, or lambda, or macro are acceptable
Standard Loopholes are forbidden
This is code-golf, so lower number of bytes are better

Edit : Correction applied on some test cases

Japt, 28 27 24 bytes
-1 byte from @kamil <3, -3 from @Shaggy :o. These guys are genius
ä- ô>2n)¯J lÉ mx x²+A*Uo

Try it online! or Test it all

Japt, 28 bytes, prev approach
Naive Way.
Important Input should start with 0 to work correctly (in some cases)
o *A+UóÈÄ¦Y©Y>XÃl>2 ®ä- xÃxp

Try it online! or Test it all

27 bytes

Quick 3 byte saving

JavaScript (ES7), 72 bytes
a=>a.map(v=>(v-p>1?r=c++?r:p:t+=(c>1)*(c=0,p-r)**2,p=v),t=c=p=0)&&t+p*10

Try it online!
Commented
a =>                  // a[] = input array
  a.map(v => (        // for each value v in a[]:
      v - p > 1 ?     //   if the difference with the previous floor is greater than 1:
        r = c++ ?     //     increment the combo counter c; if c was not equal to 0:
          r           //       leave r unchanged
        :             //     else:
          p           //       set r (reference floor) to the previous floor p
      :               //   else:
        t +=          //     update t only ...
          (c > 1) * ( //     ... if we have a multi-floor jump combo of at least 2 jumps
            c = 0,    //     reset c to 0
            p - r     //     compute the total number of floors jumped in the combo
          ) ** 2,     //     square it and add it to t
      p = v           //   set the previous value p to v
    ),                //
    t = c = p = 0     //   start with t = c = p = 0
  ) &&                // end of map()
  t + p * 10          // add the final floor multiplied by 10 to t

J, 54 bytes
[:((10*{:)+1#.[:}:]((2<#)*[:*:{:-{.);.1~1,2>2-~/\])0&,

Try it online!
May add explanation later.  For now here's an ungolfed and a parsed version:
ungolfed
[: ((10 * {:) + 1 #. [: }: ] ((2 < #) * [: *: {: - {.);.1~ 1 , 2 > 2 -~/\ ]) 0&,

parsed
┌──┬─────────────────────────────────────────────────────────────────────────────────────────────────────────┬───────┐
│[:│┌─────────┬─┬───────────────────────────────────────────────────────────────────────────────────────────┐│┌─┬─┬─┐│
│  ││┌──┬─┬──┐│+│┌─┬──┬────────────────────────────────────────────────────────────────────────────────────┐│││0│&│,││
│  │││10│*│{:││ ││1│#.│┌──┬──┬────────────────────────────────────────────────────────────────────────────┐│││└─┴─┴─┘│
│  ││└──┴─┴──┘│ ││ │  ││[:│}:│┌─┬────────────────────────────────────────┬───────────────────────────────┐││││       │
│  ││         │ ││ │  ││  │  ││]│┌────────────────────────────────────┬─┐│┌─┬─┬─────────────────────────┐│││││       │
│  ││         │ ││ │  ││  │  ││ ││┌─────────────────────────────┬──┬─┐│~│││1│,│┌─┬─┬───────────────────┐││││││       │
│  ││         │ ││ │  ││  │  ││ │││┌───────┬─┬─────────────────┐│;.│1││ │││ │ ││2│>│┌─┬─────────────┬─┐│││││││       │
│  ││         │ ││ │  ││  │  ││ ││││┌─┬─┬─┐│*│┌──┬──┬─────────┐││  │ ││ │││ │ ││ │ ││2│┌─────────┬─┐│]││││││││       │
│  ││         │ ││ │  ││  │  ││ │││││2│<│#││ ││[:│*:│┌──┬─┬──┐│││  │ ││ │││ │ ││ │ ││ ││┌─────┬─┐│\││ ││││││││       │
│  ││         │ ││ │  ││  │  ││ ││││└─┴─┴─┘│ ││  │  ││{:│-│{.││││  │ ││ │││ │ ││ │ ││ │││┌─┬─┐│/││ ││ ││││││││       │
│  ││         │ ││ │  ││  │  ││ ││││       │ ││  │  │└──┴─┴──┘│││  │ ││ │││ │ ││ │ ││ ││││-│~││ ││ ││ ││││││││       │
│  ││         │ ││ │  ││  │  ││ ││││       │ │└──┴──┴─────────┘││  │ ││ │││ │ ││ │ ││ │││└─┴─┘│ ││ ││ ││││││││       │
│  ││         │ ││ │  ││  │  ││ │││└───────┴─┴─────────────────┘│  │ ││ │││ │ ││ │ ││ ││└─────┴─┘│ ││ ││││││││       │
│  ││         │ ││ │  ││  │  ││ ││└─────────────────────────────┴──┴─┘│ │││ │ ││ │ ││ │└─────────┴─┘│ ││││││││       │
│  ││         │ ││ │  ││  │  ││ │└────────────────────────────────────┴─┘││ │ ││ │ │└─┴─────────────┴─┘│││││││       │
│  ││         │ ││ │  ││  │  ││ │                                        ││ │ │└─┴─┴───────────────────┘││││││       │
│  ││         │ ││ │  ││  │  ││ │                                        │└─┴─┴─────────────────────────┘│││││       │
│  ││         │ ││ │  ││  │  │└─┴────────────────────────────────────────┴───────────────────────────────┘││││       │
│  ││         │ ││ │  │└──┴──┴────────────────────────────────────────────────────────────────────────────┘│││       │
│  ││         │ │└─┴──┴────────────────────────────────────────────────────────────────────────────────────┘││       │
│  │└─────────┴─┴───────────────────────────────────────────────────────────────────────────────────────────┘│       │
└──┴─────────────────────────────────────────────────────────────────────────────────────────────────────────┴───────┘

C++, 202 190 188 187 184 181 177 170 166 164 bytes
int f(int*a,int l){int r=a[l-1]*10,i=0,j,k,s;for(;i<l;i++)for(j=l;s=j-->i;s&&j-i>1&&~j+l?r+=(a[i]-a[j])*(a[i]-a[i=j]),j=l:0)for(k=j;k-i;)s*=a[k--]-a[k]>1;return r;}

Try it online!
Input must begin with 0.
-11 bytes thanks to @ceilingcat

Updated, @ceilingcat

source: Stack Exchange

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/

sort: votes


text:
9erilous 9ermutations
Note: This is an attempt at recycling guest271314's permutation question(s)
There's an interesting pattern that forms when you find the differences between lexographically sorted permutations of base 10 numbers with ascending unique digits. For example, 123 has permutations:
123 132 213 231 312 321

When you find the differences between these, you get the sequence
9 81 18 81 9

Which are all divisible by nine (because of the digit sum of base 10 numbers), as well as being palindromic.
Notably, if we use the next number up, 1234, we get the sequence
9 81 18 81 9 702 9 171 27 72 18 693 18 72 27 171 9 702 9 81 18 81 9

Which extends the previous sequence while remaining palindromic around \$693\$. This pattern always holds, even when you start using more that 10 numbers, though the length of the sequence is \$n!-1\$ for \$n\$ numbers. Note that to use numbers above 0 to 9, we don't change to a different base, we just multiply the number by \$10^x\$, e.g. \$ [1,12,11]_{10} = 1*10^2 + 12*10^1 + 11*10^0 = 231\$.
Your goal is to implement this sequence, by returning each element as a multiple of nine. For example, the first 23 elements of this sequence are:
1 9 2 9 1 78 1 19 3 8 2 77 2 8 3 19 1 78 1 9 2 9 1

Some other test cases (0 indexed):
23     => 657
119    => 5336
719    => 41015
5039   => 286694
40319  => 1632373
362879 => 3978052
100    => 1
1000   => 4
10000  => 3
100000 => 3

Rules:

The submission can be any of:

A program/function that takes a number and returns the number at that index, either 0 or 1 indexed.
A program/function that takes a number \$n\$ and returns up to the \$n\$th index, either 0 or 1 indexed.
A program/function that outputs/returns the sequence infinitely.

The program should be capable of theoretically handling up to the \$11!-1\$th element and beyond, though I understand if time/memory constraints make this fail. In particular, this means you cannot concatenate the digits and evaluate as base 10, since something like \$012345678910\$ would be wrong.
This is code-golf, so the shortest implementation for each language wins!

Notes:

This is OEIS A217626
I am offering a bounty of 500 for a solution that works out the elements directly without calculating the actual permutations.
The sequence works for any contiguous digits. For example, the differences between the permutations of \$ [1,2,3,4]_{10} \$ are the same as for \$[-4,-3,-2,-1]_{10}\$.

What's the tie breaker for the bounty?

There is little point in "work out the elements directly" since computing the permutation itself takes linear time (in the size of the input) (right?), which is pretty good already. You just want to see cool methods?

Another interesting test case is $10!-1$ (3628799 => -83676269) which I think is the first negative term.

@user202729 Maybe the OP wants some log time or constant time algorithm? Because this is an OEIS sequence, such an algorithm may help research.

@shieru By "size of the input" I mean "number of bits used to represent the input" which is log(n).

@user202729 I know, because basically we just need $O(\Gamma^{-1}(n))$ steps. But I'd also like to know whether there's a log(log(n)) or constant time algorithm

Jelly, 9 bytes
,‘œ?ŻḌI÷9

Try it online! (print the n'th element)
Try it online! (20 first elements)
Explanation:
      I÷9      Compute the difference divided by 9 between
 ‘             the (n+1)th
  œ?           permutation
,              and
               the (n)th
  œ?           permutation
    Ż          of [0,1,2,...n]
     Ḍ         converted to decimal.

(Jelly has the builtin œ? which computes the nth permutation of a list in approximately linear time. Quite useful.)

Charcoal, 71 bytes
≔⟦Ｎ⊕θ⟧ηＷ⌈η≧÷Ｌ⊞ＯυＥη﹪κ⊕Ｌυη≔⁰δＦ²«≔Ｅυλζ≔⟦⟧ηＦ⮌Ｅυ§κι«⊞η§ζκ≔Φζ⁻μκζ»≦⁻↨ηχδ»Ｉ÷δ⁹

Try it online! Link is to verbose version of code. Explanation:
≔⟦Ｎ⊕θ⟧η

Get a list containing the input and one more than the input.
Ｗ⌈η

Repeat until both values are zero.
≧÷Ｌ⊞ＯυＥη﹪κ⊕Ｌυη

Perform factorial base conversion on both values. This is the first time I've actually used ≧ on a list!
≔⁰δ

Clear the result.
Ｆ²«

Loop over each factorial base number.
≔Ｅυλζ

Make a list of the digits from 0 to length - 1.
≔⟦⟧η

Initialise the result to an empty list.
Ｆ⮌Ｅυ§κι«

Loop over the digits of the factorial base number.
⊞η§ζκ

Add the next permutation digit to the result.
≔Φζ⁻μκζ»

Remove that digit from the list.
≦⁻↨ηχδ»

Convert the permutation as a base 10 number and subtract the result so far from it.
Ｉ÷δ⁹

Divide the final result by 9 and cast to string.

Perl 6, 82 bytes
-2 bytes thanks to Jo King
->\n{([-] map {$/=[^n];:10[map {|splice $/,$_,1},[R,] .polymod(1..n-2)]},n+1,n)/9}

Try it online!
0-indexed. Doesn't enumerate all permutations. Should theoretically work for all n, but bails out for n > 65536 with "Too many arguments in flattening array".
The following 80 byte version works for n up to 98!-2 and is a lot faster:
{([-] map {$/=[^99];:10[map {|splice $/,$_,1},[R,] .polymod(1..97)]},$_+1,$_)/9}

Try it online!
The following 53 byte version should theoretically work for all n, but bails out for n >= 20 with "refusing to permutate more than 20 elements".
{[-](map {:10[$_]},permutations(1..$_+1)[$_,$_-1])/9}

Try it online!

JavaScript (Node.js), 134 bytes
n=>(F=_=>f>n?((G=(n,z=0,x=f,y=l,b=[...a])=>y?G(n%(x/=y),+b.splice(n/x,1)+z*10,x,y-1,b):z)(n--)-G(n))/9:F(a.push(++l),f*=l))(a=[l=f=1])

Try it online!
1-indexed.
@guest271314's opinion is right. Direct permutation computation is shorter...
Explanation
n=>(                           // Function -
 F=_=>                         //  Helper func to calculate length needed
 f>n?                          //   If f > n (meaning the length is enough) -
  (
   (
    G=(                        //    Helper func to calculate permutation value -
     n,
     z=0,                      //     Initial values
     x=f,                      //     Made as copies because we need to alter
     y=l,                      //     these values and the function will be
     b=[...a]                  //     called twice
    )=>
    y?                         //     If still elements remaining -
     G(
      n%(x/=y),                //      Get next element
      +b.splice(n/x,1)+z*10,   //      And add to the temporary result
      x,
      y-1,                     //      Reduce length
      b                        //      Remaining elements
     )
    :z                         //     Otherwise return the permutation value
   )(n--)-G(n)                 //    Calculate G(n) - G(n - 1)
  )/9                          //    ... the whole divided by 9
 :F(
  a.push(++l),                 //   Otherwise l = l + 1, push l into the array
  f*=l                         //   ... and calculate l!
 )
)(
 a=[l=f=1]                     //  Initial values
)

Original solution (159 bytes)
n=>(x=l=t=0n,P=(a,b=[])=>n?""+a?a.map(z=>P(a.filter(y=>y-z),[...b,z])):(v=b.reduce((u,y)=>u=u*10n+y),x?--n?0:t=v-x:0,x=v):0)([...Array(n+1))].map(_=>++l))&&t/9n

Try it online!
Link is to a longer version made for performance. Array(n+1) becomes Array(Math.min(n+1,15)) in order to make demo work. Theoretically works up to infinity (up to stack limit in practice).
Explanation
I mean there's too much to explain.
n=>(                             // Function
 x=l=t=0n,                       // Initialization
 P=(                             // Function to determine the permutation -
  a,                             //  remaining items
  b=[]                           //  storage
 )=>
 n?                              //  if we haven't reached the required permutation yet -
  ""+a?                          //   if we haven't the last layer of loop -
   a.map(                        //    loop over the entries -
    z=>
    P(                           //     recurse -
     a.filter(y=>y-z),           //      pick out the selected number
     [...b,z]                    //      append to next
    )
   )
  :(                             //   if we are at the last layer -
   v=b.reduce((u,y)=>u=u*10n+y), //    calculate the value of the permutation
   x?                            //    if not the first number -
    --n?                         //     if not the last -
     0                           //      do nothing
    :t=v-x                       //     else calculate difference
   :0,                           //    else do nothing
   x=v                           //    record ot anyway
  )
 :0                              //   else do nothing
)
(
 [...Array(n+1)].map(_=>++l)     // the list of numbers to permute
)&&t/9n                          // last difference divided by 9

FWIW, Given that this implementation does not return all differences up to n, this  solution https://stackoverflow.com/a/34238979 provides a means to get two adjacent permutations, or number representations of permutations directly by index, which when golfed, should reduce the necessary code to produce the output (f(n) - f(n-1))/9 for this selected answer type consistent with the rule "A program/function that takes a number and returns the number at that index, either 0 or 1 indexed.".

Pyth, 15 14 bytes
.+m/i.PdSQT9,h

Returns the nth term. Try it here.
.+                     Find the differences between adjacent elements of
   m                   mapping lambda d:
      .PdSQ                the dth permutation of input,
     i     T               converted to base 10
    /       9              divided by 9
             ,         over [Q+1,Q]
               h Q
               Q

J, 44, 41 bytes
(9%~[:(2-~/\])i.(10#.1+A.)[:i.@>.!inv)@>:

Try it online!
Note: works even for 10! test case, but loses some precision there...
original explanation
(9 %~ [: (2 -~&(10&#.)/\ ]) 1 + i. A. i.@>.@(!inv))@>:
(                                                 )@>: NB. add one to input
                                                       NB. since n-1 deltas
                                                       NB. gives n results
                                                       NB. call that "n"
(                               i.                )    NB. take the first n
(                                  A.             )    NB. lexicographically
                                                       NB. sorted items of
(                                     i.@         )    NB. 0 up to...
(                                        >.@      )    NB. the ceil of...
(                                           (!inv))    NB. the inverse of
                                                       NB. the factorial
(                           1 +                   )    NB. add 1 so our
                                                       NB. lists start at 1
                                                       NB. instead of 0
(     [: (                )                       )    NB. apply what's in
                                                       NB. parens to that
                                                       NB. list of lists
(        (2 -~        /\ ])                       )    NB. take successive
                                                       NB. differences BUT
(        (    &(10&#.)    )                       )    NB. convert each list
                                                       NB. to a base 10
                                                       NB. number first
(9 %~                                             )    NB. and divide every
                                                       NB. items of the
                                                       NB. result by 9

JavaScript (ES6), 112 bytes
Very similar to Shieru Asakoto's algorithm.
n=>(g=N=>(h=a=>k>n?(F=r=>--i?F(+a.splice(N/(k/=i),1)+r*10,N%=k):r/9)``:h([i+1,...a],k*=i++))([i=k=1]))(n++)-g(n)

Try it online!

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
Outline words with their letters
For the purposes of the current challenge to "outline" a word means to surround it successively with its own letters, starting with the last one, and finally to replace the original word in the center with spaces:
       oooooo
       onnnno
on ->  on  no
       onnnno
       oooooo

Task:
Given a list of words, consisting only of lowercase and/or uppercase English letters, outline each word and display all the resulting blocks next to each other horizontally, separated by a column of single space, vertically aligned at the centers of the blocks.
You can write a full program, or a function.
Input:
A list of words, or if you prefer - a space- or other symbol- delimited string
Output:
The ASCII representation of the blocks for the outlined words. Leading/trailing
whitespaces are permitted.
Test cases:
Input 1: ["code", "golf"] (or "code golf")
Output 1:

    cccccccccccc gggggggggggg
    cooooooooooc goooooooooog
    coddddddddoc gollllllllog
    codeeeeeedoc golfffffflog
    code    edoc golf    flog
    codeeeeeedoc golfffffflog
    coddddddddoc gollllllllog
    cooooooooooc goooooooooog
    cccccccccccc gggggggggggg

Input 2: ["I", "am", "just", "a", "man"]  (or "I am just a man")
Output 2:

           jjjjjjjjjjjj
           juuuuuuuuuuj     mmmmmmmmm
    aaaaaa jussssssssuj     maaaaaaam
III ammmma justtttttsuj aaa mannnnnam
I I am  ma just    tsuj a a man   nam
III ammmma justtttttsuj aaa mannnnnam
    aaaaaa jussssssssuj     maaaaaaam
           juuuuuuuuuuj     mmmmmmmmm
           jjjjjjjjjjjj

Winning criteria:
The shortest code in bytes in each language wins. I will greatly appreciate if you comment/explain your code and approach.

Can we assume there is at least one word?

@Pietu1998 Yes, there always be at least one word

@Kevin Cruijssen Transpose?

Canvas, 22 20 bytes
ｌ ＊；±２１＊｛；ｌ└＊ｅ⟳｝ ］ｒ⤢

Try it here!
Explanation:
{                 ]    map over the inputs
 l *                     array of length spaces - the canvas of the current word
    ;                    get the word back on top
     ±                   reverse it
      21*                repeat each character twice
         {      }        for each character
          ;l└              push the height of the item below (the canvas)
             *             repeat the character that many times vertically
              e            and encase the canvas in that char column
               ⟳           and rotate it clockwise for encasing the next time
                 ∙      push another space as the separator of words
                   r   center the words
                    ⤢  and transpose the final output (as everything was built vertically)

Charcoal, 35 bytes
ＦＡ«≔ＬιθＭθ↑Ｆθ«Ｂ⁻×³θ⊗κ⊕⊗⁻θκ§ικ↘»Ｍ⊕⊗θ→

Try it online! Link is to verbose version of code. Explanation:
ＦＡ«

Loop over the input list.
≔Ｌιθ

Get the length of the current word.
Ｍθ↑

Move to the top left corner of the resulting outline.
Ｆθ«

Loop once for each character.
Ｂ⁻×³θ⊗κ⊕⊗⁻θκ§ικ

Draw a box of the appropriate height, width and character.
↘»

Move to the top left corner of the next box.
Ｍ⊕⊗θ→

Move to the next outline.

Haskell, 188 183 174 171 167 bytes
-9 -13 bytes thanks to Laikoni.
e=[]:e
c#a=k c<$>k(c<$a!!0)a
k c s=c:s++[c]
f w=foldr(#)[p w]w
p=(' '<$)
s w=unlines.map unwords.foldr(zipWith(:))e$until(\a->all((p a>=).p)$f<$>w)(k=<<p.head)<$>f<$>w

Try it online!

\a->and[p a>=p x|x<-f<$>w] can be \a->all((p a>=).p)$f<$>w and k c=(++[c]).(c:) can be k c s=c:s++[c].

Pyth, 34 33 bytes
Jsm+;uCjR*2HG_.iddm\ dQjCm.[lJd;J

Try it online.
Dumps out a whole bunch of extra whitespace, but that's allowed by the challenge.
Explanation

m…Q does the following for each word d in the input Q:

m\ d maps the word with x => " ", essentially creating the list [" ", ..., " "] with as many items as the word has letters.
.idd interleaves the word with itself, repeating the word's letters twice. _ reverses this string. word becomes ddrrooww.
u starts with G = the array of spaces, and applies the following with each letter in the interleaved string in H:

*2H repeats the character twice.
jR…G puts each string in G between the pair of characters.
C swaps rows and columns. When these three steps are done twice with the same character in H, this outlines the lines in G with that character.

We now have the columns for the outlined word d. +; prepends a space column.

s flattens the array of columns for each word, and J saves it in the variable J.
m…J does the following for each column of the output:

.[lJd; pads both sides of the column with spaces so that the length of the column is equal to the number of columns. This is always sufficient padding to make the columns align vertically.

C turns the columns to rows and j joins the rows with newlines.

Alternative solution, 33 bytes
j.tsm.[L\ l+dsQ+;uCjR*2HG_.iddm\

Try it online.
Note that there is a trailing space. Mostly the same algorithm, except only pads columns on the top and then transposes with space fill.

R, 189 bytes
function(x,S=32,`+`=rbind,`*`=cbind)cat(intToUtf8(Reduce(`+`,Map(function(s,K=utf8ToInt(s),o=S-!K){for(i in rev(K))o=i+i*o*i+i
for(j in(0:(max(nchar(x))-nchar(s)))[-1])o=S*o*S
o+S},x))+10))

Try it online!
A collaboration between digEmAll and myself in chat.
function(x){
 S <- 32			# space
 `+` <- rbind			# alias for rbind
 `*` <- cbind			# alias for cbind
 outlineWord <- function(s){	# function to construct the outline for each word
  chars <- utf8ToInt(s)		# convert to code points
  output <- S - !chars		# replace each char with 32 (space)
  for(i in rev(chars))
   o <- i + i * o * i + i	# o <- rbind(i,cbind(i,o,i),i)
  for(j in(0:(max(nchar(x))-nchar(s)))[-1])
   o <- S * o * S		# pad with spaces
   o + S}			# return with an additional row of spaces between words
 outlines <- Map(outlineWord,x)	# apply outlineWord to each element of x
 outlines <- Reduce(`+`,outlines)# reduce by rbind
 outlines <- outlines+10	# add row of newlines
 cat(intToUtf8(outlines))	# convert back to strings and print
}

187 with an obvious alias

@J.Doe it's community wiki so feel free to edit that in :-)

Stax, 26 25 bytes
¢π‼○MªΘ└ƒ∩┘?◙↕)fY╨nu⌂E┴6X

Run and debug it

05AB1E, 46 bytes
εg©;ò<Uyηε¤®∍«®>∍}yð«©ª®Xиª˜».º.∊}¶«».C.B€SζJ»

Not too happy about it, but I'm glad it's working.
Try it online or verify all test cases.
Explanation:
ε                             # Map `y` over the (implicit) input-list
 g                            #  Take the length of the current item
  ©                           #  Store it in the register (without popping)
   ;                          #  Halve it
    ò                         #  Ceil and cast to integer at the same time
     <                        #  Decrease it by 1
      U                       #  Pop and store it in variable `X`
 yη                           #  Take the prefixes of the current string `y`
   ε       }                  #  Map over these prefixes:
    ¤                         #   Take the last character of the string
     ®×                       #   Increase it to a size equal to the length from the register
       «                      #   Append it to the current prefix
        ®>                    #   Take the length from the register, and add 1
          ∍                   #   Shorten the string to that size
 y                            #  Push the string `y` again
  ð«                          #  Append a space
    ©                         #  Store it in the register (without popping)
     ª                        #  Append it at the end of the list of modified prefixes
      ®                       #  Push the string with space from the register again
       Xи                     #  Repeat it `X` amount of times
         ª                    #  Append them to the list
          ˜                   #  Flatten to remove the empty appended list if `X` was 0
           »                  #  Join by newlines
            .º.∊              #  Intersect mirror both horizontally and vertically
                }             # Close outer map
                 ¶«           # Append a newline after each (for the space delimiters)
                   »          # Join everything by newlines
                    .C        # Centralize it horizontally
                              # (too bad a centralize vertically isn't available..)
                      .B      # Split on newlines again
                        €S    # Convert each line to a list of characters
                          ζ   # Zip, swapping rows/columns (with space filler by default)
                           J  # Join the loose characters of every line to a string again
                            » # Join the lines by newlines (and output implicitly)

APL (Dyalog Classic), 57 51 50 bytes
{⍉⊃⍪/,/((⊢-⌈/)≢¨⍵)⌽↑{⍪¨↓0 1↓⍕,∘⍉∘⌽⍣4/⍵,⊂⍉⍪¯1/⍵}¨⍵}

Try it online!


text:
Doce logf a string swapper
Challenge
Take an input string \$s\$, and split it into words \$w_1, w_2, ..., w_n\$. If the amount of words is odd, then return \$s\$. Otherwise, for each word: Take the second last letter, and swap it with the first letter keeping capitalization positions. So GolF becomes LogF.
Now check if the amount of words is a multiple of 2, if they are,
then take the new words and make another set of words \$q_1, q_2, ..., q_{n/2}\$, where \$q_n\$ is a concatenation of \$w_n\$ and \$w_{2n}\$ before applying the whole thing again to the \$q\$ words.
If the amount of words isn't a multiple of 2, then return \$w\$ separated by spaces.

Example
String: Hello bye hey world woo doo.

Split it: [Hello, bye, hey, world, woo, doo]
Is the length an even number? Yes, proceed
Swap the first and second-last letters: [Lelho, ybe, ehy, lorwd, owo, odo]
Is the length an even number? Yes, make new groups of 2: [Lelho ybe, ehy lorwd, owo odo]
Swap again: [Belho yle, why lored, dwo ooo]
Is the length an even number? No, return Belho yle why lored dwo ooo

Notes

Input words will always have more than 2 characters
Input will always be letters from a-z, capital or lowercase, and separated by a single space
Standard loopholes and Default I/O rules apply
You may not take input in the form of a word list/array
You don't need to handle edge cases

Test Cases
Hello bye hey world woo doo   --> Belho yle why lored dwo ooo
Code golf awesome stuff       --> Goce lodf swesoae ftumf
Very hard code golf challenge --> Very hard code golf challenge (odd length)
Very hard coding stuff        --> Hevy rard sodicg ftunf

Scoring
This is code-golf, so the shortest code (in bytes) wins.

will all words contain min 3 letters?

@Jonah Yes, stated in question

Shouldn't the last test case return Nevy rard sodicg ftuhf?

How's that? Let me check again..

Did you mean to type "$w_{n+1}$" instead of "$w_{2n}$" in "$q_n$ is a concatenation of $w_n$ and $w_{2n}$"?

@EriktheOutgolfer It shows up as w2n for me...

@nwellnhof Oh yeah, fixing

What? Actually, in your example, it looks like $q_n$ is $w_{2n-1}\space w_{2n}$, not $w_n\space w_{2n}$.

Also "before applying the whole thing again to the q words" is misleading because in step 5 of your example, you don't test whether the number of words is odd before swapping letters.

@nwellnhof How is it misleading? In step 4 I checked where the number was even ("Now check if the amount of words is a multiple of 2") then in step 5 I applied it to the new words

But in step 4 you also make new groups which leads to the number of words becoming odd. This isn't checked in step 5 which contradicts the challenge description.

If we have an even number of words at step #2, we still have an even number of words at step #4, don't we?

@Arnauld But it's just an initial check at the very beginning to make sure we don't have to split an odd-lengthed list

I believe either the 2nd or the last test case is wrong. They have the same number of words and by applying exactly the same logic, I get Goce lodf swesoae ftumf and Hevy rard sodicg ftunf respectively.

@Arnauld Isn't Hevy rard sodicg ftunf the last case that I provided? And about the 2nd one, fixing that. I'm generating these test cases by hand since I don't have a program to do it which is the reason for this

I would add a test cases which has some capitalization in between, instead of only at the beginning of the sentence. I was just about to post a solution when it was closed as unclear.. I think the main reason is because you are talking about words, even though in your examples you split the list into two groups (where each group is two words). It might be better to not use the term words, but instead use strings or something like that: Take a list of strings; if this list is even: swap for each string the first and second-to-last, then merge every 2 with a space delimiter, and continue

I think the most confusing part is your example, which contradicts your challenge description. You split the input by spaces, and check if it's even: it is, so proceed. Then you swap for each, and split into groups of two. But then you swap again without checking if the list is odd, which it is. I would expect the output Lelho ybe ehy lorwd owo odo for input Hello bye hey World woo doo. 1. Split by spaces; 2. Check if even: yes, so proceed; 3. Swap for each word; 4. Group per 2 (["Lelho ybe", "ehy lorwd", "owo odo"]); 5. Check if even: no, so output joined by spaces.

Node.js v10.9.0, 171 bytes
s=>(h=a=>a.map(w=>Buffer(w).map((c,i,a)=>(i?i-p?c:x:a[x=c,p=w.length-2])&31|c&96)+''),g=n=>n&1?a.join` `:g(n/2,a=h(h(a).join` `.match(/\S+ \S+/g))))((a=s.split` `).length)

Try it online!
Commented
The helper function \$h\$ takes an array of words \$a\$ and apply the letter transformation to each of them.
h = a =>                     // a[] = input array
  a.map(w =>                 // for each word w in a[]:
    Buffer(w)                //   convert w to a Buffer
    .map((c, i, a) =>        //   for each ASCII code c at position i in this array a[]:
      ( i ?                  //     if this is not the first letter:
          i - p ?            //       if this is not the second last letter:
            c                //         just use c
          :                  //       else:
            x                //         use the backup x of the first letter
        :                    //     else:
          a[                 //       use the second last letter
            x = c,           //       save the first letter in x
            p = w.length - 2 //       p = index of the second last letter
          ]                  //
      ) & 31                 //     use the lower bits of the above character
      | c & 96               //     use the upper bits of the current character (case)
    ) + ''                   //   end of inner map(); coerce the Buffer back to a string
  )                          // end of outer map()

Main part:
s => (                       // s = input string
  g = n =>                   // g = recursive function taking the number of words n
    n & 1 ?                  // if n is odd:
      a.join` `              //   stop recursion and return a[] joined with spaces
    :                        // else:
      g(                     //   do a recursive call to g:
        n / 2,               //     with n / 2
        a = h(               //     update a[]:
          h(a)               //       apply the letter transformation
          .join` `           //       join with spaces
          .match(/\S+ \S+/g) //       make groups of 2 words
        )                    //     apply the letter transformation again on the result
      )                      //   end of recursive call
)((a = s.split` `).length)   // initial call to g with a[] = list of words, n = length

Python 3, 189 bytes
J=' '.join
s=input().split()
f=lambda w,i:(w[~i].lower(),w[~i].upper())[w[i-1].isupper()]
while~len(s)&1:s=[f(w,1)+w[1:-2]+f(w,-1)+w[-1]for w in s];s=[*map(J,zip(s,s[1:]))][::2]
print(J(s))

Try it online!

Charcoal, 68 bytes
≔⪪Ｓ θＦ¬﹪Ｌθ²«≔¹ηＷ¬﹪Ｌθη«≔ＥＥ⪪θη⪫λ ⭆⭆Ｅλ⁻⁻Ｌλξ²§λ⎇∧νξξν⎇№α§λξ↥ν↧νθ≔²η»»⪫θ

Try it online! Link is to verbose version of code. Explanation:
≔⪪Ｓ θ

Split the input on spaces.
Ｆ¬﹪Ｌθ²«

Do nothing if the number of words is odd.
≔¹η

Don't pair the words up on the first pass.
Ｗ¬﹪Ｌθη«

Repeat while the number of words is even.
≔ＥＥ⪪θη⪫λ ...θ

Pair the words up, map over the paired words, and save the result.
Ｅλ⁻⁻Ｌλξ²

Map each character index to the length of the word minus the index minus 2.
⭆...§λ⎇∧νξξν

Map each character to itself unless its index or the above calulation is zero in which case use the character at the index given by the above calculation.
⭆...⎇№α§λξ↥ν↧ν

Map each character to upper or lower case depending on whether the original character of that word was upper or lower case.
≔²η»»

Pair the words up on successive passes.
⪫θ

Join the (remaining) words on spaces and implicitly print.


text:
Gold nugget storage
Given a positive integer, write it as the sum of numbers, where each of them is in \$\{kt|k\in{1,9,81},t\in{1,2,3,...,64}\}\$. How many numbers at least are used? Shortest code win.
Samples:
Input  Output Method
1      1      1
2      1      2
64     1      64
65     2      64+1
72     1      72
343    2      342+1
576    1      576
577    2      576+1
5184   1      5184
46656  9      5184+5184+5184+5184+5184+5184+5184+5184+5184
5274   2      5184+90

Sandbox

Could you give slightly more detail/put into words how the input results in the output?

@Quintec All numbers in column Method are in the given set, and there's no way to make fewer ones that sum to the input

If something requires clarification in the comments, it would be useful to edit the challenge to include that clarification

@trichoplax I don't know where to insert it

Is it basically a sort of change-making problem ? With the coins denominations being in the set {1,9,81} × {1...64} ?

Change making problem for minecraft gold nuggets apparently

Are you trying to minimize the number of items or number of stacks?

@fəˈnɛtɪk number of stacks for minecraft picture, item(numbers to be added) for the problem

I suggest adding 5274 = 64*81 + 10*9 as a test case, this checks if answers take as many blocks as possible if there are more than 576 nuggets and get  64*81 + 1*81 + 9*1 (as mine did)

Jelly, 17 bytes
64R×9;Ɗ⁺ff€¥@ŒṗẈṂ

Try it online!
-1 thanks to Jonathan Allan.
Explanation (you can't test for inputs larger than 58 over TIO):
64R×9;Ɗ⁺ff€¥@ŒṗẈṂ Arguments: x
64R               [1..64]
   ×9;Ɗ           Multiply by 9, prepend to original list
       ⁺          Do the above once more
             Œṗ   Positive integer partitions of x
           ¥@     Call with reversed arguments (x = partitions, y = flattened outer product)
         f€         For each partition in x, keep the elements that are in y
        f           Keep the elements of x that have remained intact after the above
               Ẉ  Lengths of the remaining partitions
                Ṃ Minimum

Since the output in testable area is trivial, can't quite check?

@l4m2 You can't do so over TIO, but you might be able to do so if you install Jelly locally. That's why I've added the explanation.

JavaScript (ES6), 72 66 57 56 bytes
Saved 1 byte thanks to @nwellnhof
f=n=>n&&1+f(n<5184?n>64&&n%(n<576?9:n>719?81:72):n-5184)

Try it online!

@nwellnhof This would fail for several values (576, 632, 633, ...)

I see. But f=n=>n&&1+f(n<5184?n>64&&n%(n<576?9:n<648?72:81):n-5184) (56 bytes) should work, right?

@nwellnhof Yes, it does. :)

05AB1E, 30 27 bytes
ŽK≠‰`91vDy64*›i1sy9*%]64/îO

Try it online! or verify all test cases
-3 bytes thanks to Kevin Cruijssen
This is my first 05AB1E submission, so I am sure that this can be optimized.

Not sure why you opted to choose the legacy version, since your answer also works in the new Elixir rewrite, but in the new version 5184 can be ŽK≠. In addition, the S after 91 can be removed since it's done implicitly; and }} can be ] (although you'd still need }} in your test suite on TIO). Try it online or verify all test cases.

@KevinCruijssen I used the legacy version because tio.run/#05ab1e redirects there and because I didn't know about multiple versions.Thanks for the tips!

Ah, I see. The legacy version is written in Python, and was used for the past few years. A few months back the Elixir rewrite was released as new version, with loads of new features. Some builtins have changed slightly, so I do still use the legacy version sometimes, but I mostly use the new version now. :) PS: If you haven't seen it yet: Tips for golfing in 05AB1E might be interesting to read through. And feel free to ask anything in the 05AB1E chat if you need help.

Perl 6, 47 bytes
{+($_,(*X-(1,9,81 X*^65)).grep(*>=0).min...^0)}

Try it online!
A greedy algorithm seems to work.

Wolfram Language (Mathematica), 66 bytes
Min[Length/@IntegerPartitions[#,All,Union[#,9#,81#]&@Range@64,#]]&

Try it online!


text:
Generate Matlab plot markers
Matlab has a useful command for visualizing data: plot. It draws data points using "markers" in 2-D space, connecting them with lines; however, for this challenge, let's ignore the lines and use only markers. In fact, only one marker.
Input: one of Matlab's marker symbols: . o x + * s d v ^ < > p h
Output: corresponding image for that marker, which is one of the following 13 icons:
To make it clearer, here are the same icons enlarged, so the pixels can be easily seen:

Take the input as a string, a char, an integer ASCII code, or anything equivalent
Produce the output by displaying the image, returning it as a function's return value, saving it to a file, etc
The image should have pixels of two different colours in it. I used blue on white, because this is what Matlab uses by default, but any other colour scheme is OK, e.g. white on black.
The image can have padding of background colour of any size
The pixels can be enlarged by any integer ratio, e.g. instead of the original 11-by-9 image for the triangle, you can output a 110-by-72 image, in which 10-by-8 blocks represent the original pixels

As a corollary of the above, you can output text with glyphs like █ instead of an image, if you can print this text properly (i.e. without gaps between glyphs) on the same system which runs the code

For quick reference, here are the bitmaps for each input:

.
0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 1 1 1 0 0 0 0
0 0 0 1 1 1 1 1 0 0 0
0 0 0 0 1 1 1 0 0 0 0
0 0 0 0 0 1 0 0 0 0 0

o
0 0 0 0 1 1 1 0 0 0 0
0 0 1 1 0 0 0 1 1 0 0
0 0 1 0 0 0 0 0 1 0 0
0 1 0 0 0 0 0 0 0 1 0
0 1 0 0 0 0 0 0 0 1 0
0 1 0 0 0 0 0 0 0 1 0
0 0 1 0 0 0 0 0 1 0 0
0 0 1 1 0 0 0 1 1 0 0
0 0 0 0 1 1 1 0 0 0 0

x
0 0 1 0 0 0 0 0 1 0 0
0 0 0 1 0 0 0 1 0 0 0
0 0 0 0 1 0 1 0 0 0 0
0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 1 0 1 0 0 0 0
0 0 0 1 0 0 0 1 0 0 0
0 0 1 0 0 0 0 0 1 0 0

+
0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 0 1 0 0 0 0 0
0 1 1 1 1 1 1 1 1 1 0
0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 0 1 0 0 0 0 0

*
0 0 0 0 0 1 0 0 0 0 0
0 0 1 0 0 1 0 0 1 0 0
0 0 0 1 0 1 0 1 0 0 0
0 0 0 0 1 1 1 0 0 0 0
0 1 1 1 1 1 1 1 1 1 0
0 0 0 0 1 1 1 0 0 0 0
0 0 0 1 0 1 0 1 0 0 0
0 0 1 0 0 1 0 0 1 0 0
0 0 0 0 0 1 0 0 0 0 0

s
0 1 1 1 1 1 1 1 1 1 0
0 1 0 0 0 0 0 0 0 1 0
0 1 0 0 0 0 0 0 0 1 0
0 1 0 0 0 0 0 0 0 1 0
0 1 0 0 0 0 0 0 0 1 0
0 1 0 0 0 0 0 0 0 1 0
0 1 0 0 0 0 0 0 0 1 0
0 1 0 0 0 0 0 0 0 1 0
0 1 1 1 1 1 1 1 1 1 0

d
0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 1 0 1 0 0 0 0
0 0 0 1 0 0 0 1 0 0 0
0 0 0 1 0 0 0 1 0 0 0
0 0 1 0 0 0 0 0 1 0 0
0 1 0 0 0 0 0 0 0 1 0
0 0 1 0 0 0 0 0 1 0 0
0 0 0 1 0 0 0 1 0 0 0
0 0 0 1 0 0 0 1 0 0 0
0 0 0 0 1 0 1 0 0 0 0
0 0 0 0 0 1 0 0 0 0 0

v
1 1 1 1 1 1 1 1 1 1 1
0 1 0 0 0 0 0 0 0 1 0
0 1 0 0 0 0 0 0 0 1 0
0 0 1 0 0 0 0 0 1 0 0
0 0 1 0 0 0 0 1 0 0 0
0 0 0 1 0 0 0 1 0 0 0
0 0 0 0 1 0 1 0 0 0 0
0 0 0 0 1 0 1 0 0 0 0
0 0 0 0 0 1 0 0 0 0 0

^
0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 1 0 1 0 0 0 0
0 0 0 0 1 0 1 0 0 0 0
0 0 0 1 0 0 0 1 0 0 0
0 0 1 0 0 0 0 1 0 0 0
0 0 1 0 0 0 0 0 1 0 0
0 1 0 0 0 0 0 0 0 1 0
0 1 0 0 0 0 0 0 0 1 0
1 1 1 1 1 1 1 1 1 1 1

<
0 0 0 0 0 0 0 0 1 0 0
0 0 0 0 0 0 1 1 1 0 0
0 0 0 0 1 1 0 0 1 0 0
0 0 0 1 0 0 0 0 1 0 0
0 1 1 0 0 0 0 0 1 0 0
1 0 0 0 0 0 0 0 1 0 0
0 1 1 0 0 0 0 0 1 0 0
0 0 0 1 1 0 0 0 1 0 0
0 0 0 0 0 1 0 0 1 0 0
0 0 0 0 0 0 1 1 1 0 0
0 0 0 0 0 0 0 0 1 0 0

>
0 0 1 0 0 0 0 0 0 0 0
0 0 1 1 1 0 0 0 0 0 0
0 0 1 0 0 1 1 0 0 0 0
0 0 1 0 0 0 0 1 0 0 0
0 0 1 0 0 0 0 0 1 1 0
0 0 1 0 0 0 0 0 0 0 1
0 0 1 0 0 0 0 0 1 1 0
0 0 1 0 0 0 1 1 0 0 0
0 0 1 0 0 1 0 0 0 0 0
0 0 1 1 1 0 0 0 0 0 0
0 0 1 0 0 0 0 0 0 0 0

p
0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 1 1 0 0 0 0 0
0 1 1 1 1 1 1 1 1 0 0
0 0 1 0 0 0 0 1 0 0 0
0 0 0 1 0 0 1 0 0 0 0
0 0 0 1 0 1 1 0 0 0 0
0 0 1 1 1 0 1 1 0 0 0
0 0 1 0 0 0 0 1 0 0 0

h
0 0 0 0 0 1 0 0 0 0 0
0 0 0 0 1 1 0 0 0 0 0
0 0 1 1 1 0 1 1 1 0 0
0 0 1 0 0 0 0 1 0 0 0
0 0 0 1 0 0 0 1 0 0 0
0 0 1 0 0 0 0 1 0 0 0
0 0 1 1 1 0 1 1 1 0 0
0 0 0 0 1 1 0 0 0 0 0
0 0 0 0 0 1 0 0 0 0 0

Any padding with zeros which exists in these bitmaps is optional. So e.g. for the . input, a 5x5 image would be sufficient.

Possibly add [tag:compression]?

Can output be unpad? (5*5 for .)

Yes. Thought it would be obvious; will clarify.

Why is the star so horribly mutilated? ergh

I am more fascinated by the fact that it's still recognizable when the pixels are small enough!

@JonathanFrech Rather than compression, I think [tag:kolmogorov-complexity] is more appropriate due to the limited number of potential inputs and direct mapping of inputs to outputs (similar to this challenge).

@Rogem I agree that [tag:kolmogorov-complexity] could fit, however such challenges generally are about constant output and only seldom allow input of any kind. Therefore I suggested [tag:compression].

Node.js, 310 bytes
Takes the ASCII code of the symbol as input.
n=>Buffer(`~A<<13)$$"~"6+'?'+6"~'81<<<18'~/973202459/~"$$)31<<A~"%;3)3;%"~~ !&(=@=-#! ~""""?""""~"%>3*,:3~~"$))1<1))$"~"'.'"~?<<<<<<<?~1)$"$)1`.split`~`[n*7%86%17]).map(c=>s+=(g=n=>n--?' █'[[...Buffer('$8$$L0$,4$(8(4T(!#""0($,|T8$F'),290,280,34,38,1051].map(c=>p+=c-32,p=0)[c-32]>>n&1]+g(n):`
`)(11),s='')&&s

Try it online!
How?
All symbols can be generated by combining \$34\$ distinct binary patterns.
Each pattern is identified with a character \$C\$ (from space to "A").
The patterns are ordered from lowest to highest, using their decimal representation \$N\$. What's actually stored is the difference \$d\$ between two consecutive patterns, plus \$32\$.
 ID |  C  | pattern     |    N |    d | d+32
----+-----+-------------+------+------+------
  0 | ` ` | 00000000100 |    4 |    4 |   36
  1 | `!` | 00000011100 |   28 |   24 |   56
  2 | `"` | 00000100000 |   32 |    4 |   36
  3 | `#` | 00000100100 |   36 |    4 |   36
  4 | `$` | 00001010000 |   80 |   44 |   76
  5 | `%` | 00001100000 |   96 |   16 |   48
  6 | `&` | 00001100100 |  100 |    4 |   36
  7 | `'` | 00001110000 |  112 |   12 |   44
  8 | `(` | 00010000100 |  132 |   20 |   52
  9 | `)` | 00010001000 |  136 |    4 |   36
 10 | `*` | 00010010000 |  144 |    8 |   40
 11 | `+` | 00010101000 |  168 |   24 |   56
 12 | `,` | 00010110000 |  176 |    8 |   40
 13 | `-` | 00011000100 |  196 |   20 |   52
 14 | `.` | 00011111000 |  248 |   52 |   84
 15 | `/` | 00100000000 |  256 |    8 |   40
 16 | `0` | 00100000001 |  257 |    1 |   33
 17 | `1` | 00100000100 |  260 |    3 |   35
 18 | `2` | 00100000110 |  262 |    2 |   34
 19 | `3` | 00100001000 |  264 |    2 |   34
 20 | `4` | 00100011000 |  280 |   16 |   48
 21 | `5` | 00100100000 |  288 |    8 |   40
 22 | `6` | 00100100100 |  292 |    4 |   36
 23 | `7` | 00100110000 |  304 |   12 |   44
 24 | `8` | 00110001100 |  396 |   92 |  124
 25 | `9` | 00111000000 |  448 |   52 |   84
 26 | `:` | 00111011000 |  472 |   24 |   56
 27 | `;` | 00111011100 |  476 |    4 |   36
 28 | `<` | 01000000010 |  514 |   38 |   70
 29 | `=` | 01100000100 |  772 |  258 |  290
 30 | `>` | 01111111100 | 1020 |  248 |  280
 31 | `?` | 01111111110 | 1022 |    2 |   34
 32 | `@` | 10000000100 | 1028 |    6 |   38
 33 | `A` | 11111111111 | 2047 | 1019 | 1051

The 29 first values \$d+32\$ can be directly converted to ASCII characters and stored as a Buffer. The last 5 ones are stored as number literals.
[...Buffer('$8$$L0$,4$(8(4T(!#""0($,|T8$F'),290,280,34,38,1051]

Using the characters \$C\$ defined above, we can encode each symbol as a string.
Example:
..█........     00100000000 --> '/'
..███......     00111000000 --> '9'
..█..██....     00100110000 --> '7'
..█....█...     00100001000 --> '3'
..█.....██.     00100000110 --> '2'
..█.......█ --> 00100000001 --> '0' --> '/973202459/'
..█.....██.     00100000110 --> '2'
..█...██...     00100011000 --> '4'
..█..█.....     00100100000 --> '5'
..███......     00111000000 --> '9'
..█........     00100000000 --> '/'

All symbols are stored in a single string, delimited with ~. We use a hash function to convert the input ASCII code into the position of the symbol in the list.

Charcoal, 163 154 152 bytes
≔█η≡θo«Ｇ→↘→²η‖Ｏ↘¬»d«Ｇ↘³↓²↘³η‖Ｏ¬»h«ＧＨ↖↑→→↑↗↓↘→→↙↓²η‖Ｏ↓».ＧX³ηpＧ↑²↙⁴↖²→⁸↙³↓³→²↓²↖³↙²←³↓²↗²↑³ηsＢ⁹η¿№x+*θ«Ｆ¬⁼θ+ＰX×⁴ηＦ¬⁼θxＰ+×⁵η»«ＧＨ←←←←←↘↓↘↓↘↘↓↘²η‖Ｏ⟲⊗⌕v>^<θ

Try it online! Link is to verbose version of code. Explanation:
≔█η

Get the █ character into a variable. As @ASCII-only explains, a properly encoded Charcoal file would use three bytes to express this character, so it needs to be in a variable as it gets used a lot. (But it's still 2 bytes shorter than the previous approach.)
≡θ

Use a switch statement for the six easy characters.
o«Ｇ→↘→²η‖Ｏ↘¬»

Handle the o by drawing one eighth of the figure and mirroring it three times.
d«Ｇ↘³↓²↘³η‖Ｏ¬»

Handle the d by drawing one quarter of the figure and mirroring it twice.
h«ＧＨ↖↑→→↑↗↓↘→→↙↓²η‖Ｏ↓»

Handle the h by drawing the top half and mirroring it.
.ＧX³η

Handle the . by drawing a diamond.
pＧ↑²↙⁴↖²→⁸↙³↓³→²↓²↖³↙²←³↓²↗²↑³η

Handle the p by drawing it manually.
sＢ⁹η

Handle the s by drawing a hollow rectangle. (This one is the last of the six because Box can take 3 parameters but the following ¿ isn't legal as a parameter.)
¿№x+*θ«Ｆ¬⁼θ+ＰX×⁴ηＦ¬⁼θxＰ+×⁵η»

Handle the x, + and *, the latter by overlapping the former.
«ＧＨ←←←←←↘↓↘↓↘↘↓↘²η‖Ｏ⟲⊗⌕v>^<θ

Draw the left half of the v, then mirror it, then rotate it if the character happens to be >, ^ or <.

Wait, doesn't handle it correctly?

@ASCII-only: well, that character isn't in Charcoal's code page, so it can't really appear in the source, can it?

If you check it, it's counted as... 3? bytes. I'm not sure if it actually works, but it should - Charcoal should have rudimentary Unicode translation for a certain number of characters after a 0xFF. I'll check later and link if it works

here

@ASCII-only Ah, I didn't know that about the 0xFF byte. It's a bit confusing because the bytes that the encoded file would need correspond to �﹪⧴ in Charcoal's code page but TIO works in Unicode characters so you can't easily demonstrate that.

I'm an idiot and added �, it shouldn't actually be there, realized when I was thinking about how the decoding worked - 0xFF will never be translated by itself

MATL, 9 bytes
1w&XG7lZG

Cheating? Maybe. Try it on MATL Online.
Literal translation of the MATLAB code plot(1,input(''));axis off (26 bytes). The online version compresses the image, but on a local machine it will simply use the MATLAB plot defaults.

I guess the consensus is that built-in functions are allowed by default, so no cheating.

@anatolyg I know, else I wouldn't have posted it. But it definitely feels like cheating ;)

Python, 58 bytes
from matplotlib.pyplot import*
plot(0,input())
axis('off')

Fun to take advantage of matplotlib doing all the heavy lifting.