Two words are anagrams of each other if the letters of one can be reordered to spell the other; e.g. ADOBE and ABODE are anagrams. An alternate way of describing it is that both words contain the s...
Somewhere Else, there was a long-standing rule that to answer a challenge, you couldn't use languages, language versions, or features that were created or introduced after the challenge was posted....
2 answers
·
posted 4y ago
by snail_
· last activity
4y ago
by user
Ruby, 67 65 bytes
-2 from Razetime
->s,a{[s.center(l=a.map(&:size).max),*a,"BOTTOM TEXT".center(l)]}
Takes the art and outputs as a list of lines.
Try it online!
Ruby, 38 bytes
Simple map and sum over the coefficients. No TIO link, this uses numbered lambda parameters which require Ruby 2.7.
->l,x{l.each_with_index.sum{_1*x**_2}}
Ahead, 20 bytes
I>:2%r
vn:/2\<
>}KO@
Control flow goes like this:
# orange path: init
I # read number
# green path: main loop
> # go east (start of loop)
: # dup inpu...
Two words are anagrams of each other if the letters of one can be reordered to spell the other; e.g. ADOBE and ABODE are anagrams. An alternate way of describing it is that both words contain the s...
jq --raw-output, 32 bytes
jq is the language of the month, apparently. Here it is! Not sure if the --raw-output flag really matters, someone let me know.
"#"*.+("
#"+" "*(.-2)+"#")*(.-1)
Try ...