text:
Quine Relay!
Quine Relay!
A quine relay of order \$n\$ is a series of programs \$P_1\dots P_n\$ in distinct languages such that each program \$P_i\$ outputs \$P_{i+1}\$ and \$P_n\$ outputs \$P_1\$.
For example, a 2-quine relay can be seen here:
Ruby → Perl 6:
This Ruby program:
$><<"print ("
p (DATA.read*2).chars.map(&:ord)
$><<".map: &chr).join"

__END__
$><<"print ("
p (DATA.read*2).chars.map(&:ord)
$><<".map: &chr).join"

__END__

outputs this Perl 6 program:
print ([36, 62, 60, 60, 34, 112, 114, 105, 110, 116, 32, 40, 34, 10, 112, 32, 40, 68, 65, 84, 65, 46, 114, 101, 97, 100, 42, 50, 41, 46, 99, 104, 97, 114, 115, 46, 109, 97, 112, 40, 38, 58, 111, 114, 100, 41, 10, 36, 62, 60, 60, 34, 46, 109, 97, 112, 58, 32, 38, 99, 104, 114, 41, 46, 106, 111, 105, 110, 34, 10, 10, 95, 95, 69, 78, 68, 95, 95, 10, 36, 62, 60, 60, 34, 112, 114, 105, 110, 116, 32, 40, 34, 10, 112, 32, 40, 68, 65, 84, 65, 46, 114, 101, 97, 100, 42, 50, 41, 46, 99, 104, 97, 114, 115, 46, 109, 97, 112, 40, 38, 58, 111, 114, 100, 41, 10, 36, 62, 60, 60, 34, 46, 109, 97, 112, 58, 32, 38, 99, 104, 114, 41, 46, 106, 111, 105, 110, 34, 10, 10, 95, 95, 69, 78, 68, 95, 95, 10]
.map: &chr).join

which in turn outputs the original Ruby program.
The challenge
The first answer will be an order \$1\$ quine relay: a normal quine. It can be in any language.
The next answer will choose a different language and create an order \$2\$ quine relay using those two languages.
And so on. The \$k\$-th answer will create an order \$k\$ quine relay using the previous \$k - 1\$ languages and a new, different language.
Winning
If, after 2 weeks, no more answers have been added, the winner is the person who answered with the highest-order quine relay.
More rules

No person may answer twice in a row.
No person may answer within an hour of their most recent post.
Languages which differ by version are considered distinct. Thus, Python 2 and Python 3 can both be part of the chain.
Languages which differ by compiler or interpreter are not considered distinct. So, Python 3 (Cython) and Python 3 are considered interchangeable but not distinct.
Each answer may order the languages in any way. If the third answer has an order of Ruby → Perl 6 → JavaScript, you are not restricted to appending a language to the end. If you were adding Java to the mix, then you could write JavaScript → Ruby → Java → Perl 6 if you so desired.

Format for answers

n. Language1 → Language2 → … → Languagen
Language1
language 1 code

Language2
language 2 code

Language3
language 3 code

…
Languagen
language n code

Feel free to add explanations anywhere in your answers.

You should add something like a 2 character minimum to prevent degenerate quine chains such as the empty string. Also, something to prevent languages that by default echo output their input. Alternatively, you can roll these into one by requiring that all outputs in the chain must be unique.

@YonatanN Actually once enough languages get added it would be hard to pull that off... would be interesting to see someone try. Although I think all so far have empty quines.

@ØrjanJohansen as of now, someone can trash the question by using a Bubblegum-type language and an empty input.

@YonatanN Hm yeah I guess there are too many ways to abuse it. (Also this kind of thing is why other answer chaining questions give the win to the second last answer.)

@YonatanN 0 or 1 character quines usually do not meet our standard definition of quine

10. Javascript → Foo → brainfuck → Wumpus → Gol><> → RAD → ><> → Python 2 → Brain-Flak → 4
Edit: For the next answer, I've golfed how the Python generates the Brain-Flak a bit more here, but I can't be bothered to update the links.
Added Gol><>. It's just a short rpH after the Wumpus code. I've also optimised the brainfuck and Brain-Flak code somewhat.
Verification!
JavaScript (Node.js)
(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);b=c(96);x=0;console.log(Q+[...`${Q}99+&;75*1-l2:8-&o@rpH${q}${q+q}rpp>o<def n(x):global l;r=p+p+f+F+P+q+(p+P)*(l-x)+Q+P if x<l else p+p+f+F+P+(p+P)*(x-l)+P;l=x;return r;''a''p=chr(40);P=chr(41);q=chr(91);Q=chr(93);f=chr(123);F=chr(125);l=4;print p+p+p+p+p+p+P+p+P+p+P+P+f+F+P+f+F+p+P+P+f+F+P+f+F+P,str().join(map(n,map(lambda x:ord(x)-48,str().join(map(lambda c:${b}600${b}+(str(c-99).zfill(2)+${b}99500${b}.zfill(10) if c>99 else str(c).zfill(2)+${b}500${b}),[`+[...`(f=${f})()`].map(c=>c.charCodeAt())+`]))[::-1]+${b}99996${b}))),${[...'pppppppPpPPfFpPPfFpPPfFpPPfFPppPpPPfFpPP'].join`+`}${q}`].map(s=>c(43).repeat(Math.max(-x+s.charCodeAt(),0))+c(45).repeat(Math.max(x-(x=s.charCodeAt()),0))+c(46)).join(c()).match(/.{1,253}/g).join(c(10)+Q))})()

Try it online!
Foo
Try it online!
brainfuck
Try it online!
Wumpus
"99+&;75*1-l2:8-&o@rpH'''rpp>o<def n(x):global l;r=p+p+f+F+P+q+(p+P)*(l-x)+Q+P if x<l else p+p+f+F+P+(p+P)*(x-l)+P;l=x;return r;''a''p=chr(40);P=chr(41);q=chr(91);Q=chr(93);f=chr(123);F=chr(125);l=4;print p+p+p+p+p+p+P+p+P+p+P+P+f+F+P+f+F+p+P+P+f+F+P+f+F+P,str().join(map(n,map(lambda x:ord(x)-48,str().join(map(lambda c:`600`+(str(c-99).zfill(2)+`99500`.zfill(10) if c>99 else str(c).zfill(2)+`500`),[40,102,61,95,61,62,123,113,61,40,99,61,83,116,114,105,110,103,46,102,114,111,109,67,104,97,114,67,111,100,101,41,40,51,57,41,59,81,61,99,40,51,52,41,59,98,61,99,40,57,54,41,59,120,61,48,59,99,111,110,115,111,108,101,46,108,111,103,40,81,43,91,46,46,46,96,36,123,81,125,57,57,43,38,59,55,53,42,49,45,108,50,58,56,45,38,111,64,114,112,72,36,123,113,125,36,123,113,43,113,125,114,112,112,62,111,60,100,101,102,32,110,40,120,41,58,103,108,111,98,97,108,32,108,59,114,61,112,43,112,43,102,43,70,43,80,43,113,43,40,112,43,80,41,42,40,108,45,120,41,43,81,43,80,32,105,102,32,120,60,108,32,101,108,115,101,32,112,43,112,43,102,43,70,43,80,43,40,112,43,80,41,42,40,120,45,108,41,43,80,59,108,61,120,59,114,101,116,117,114,110,32,114,59,39,39,97,39,39,112,61,99,104,114,40,52,48,41,59,80,61,99,104,114,40,52,49,41,59,113,61,99,104,114,40,57,49,41,59,81,61,99,104,114,40,57,51,41,59,102,61,99,104,114,40,49,50,51,41,59,70,61,99,104,114,40,49,50,53,41,59,108,61,52,59,112,114,105,110,116,32,112,43,112,43,112,43,112,43,112,43,112,43,80,43,112,43,80,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,80,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,110,44,109,97,112,40,108,97,109,98,100,97,32,120,58,111,114,100,40,120,41,45,52,56,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,108,97,109,98,100,97,32,99,58,36,123,98,125,54,48,48,36,123,98,125,43,40,115,116,114,40,99,45,57,57,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,57,57,53,48,48,36,123,98,125,46,122,102,105,108,108,40,49,48,41,32,105,102,32,99,62,57,57,32,101,108,115,101,32,115,116,114,40,99,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,53,48,48,36,123,98,125,41,44,91,96,43,91,46,46,46,96,40,102,61,36,123,102,125,41,40,41,96,93,46,109,97,112,40,99,61,62,99,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,96,93,41,41,91,58,58,45,49,93,43,36,123,98,125,57,57,57,57,54,36,123,98,125,41,41,41,44,36,123,91,46,46,46,39,112,112,112,112,112,112,112,80,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,80,112,112,80,112,80,80,102,70,112,80,80,39,93,46,106,111,105,110,96,43,96,125,36,123,113,125,96,93,46,109,97,112,40,115,61,62,99,40,52,51,41,46,114,101,112,101,97,116,40,77,97,116,104,46,109,97,120,40,45,120,43,115,46,99,104,97,114,67,111,100,101,65,116,40,41,44,48,41,41,43,99,40,52,53,41,46,114,101,112,101,97,116,40,77,97,116,104,46,109,97,120,40,120,45,40,120,61,115,46,99,104,97,114,67,111,100,101,65,116,40,41,41,44,48,41,41,43,99,40,52,54,41,41,46,106,111,105,110,40,99,40,41,41,46,109,97,116,99,104,40,47,46,123,49,44,50,53,51,125,47,103,41,46,106,111,105,110,40,99,40,49,48,41,43,81,41,41,125,41,40,41]))[::-1]+`99996`))),p+p+p+p+p+p+p+P+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+P+p+p+P+p+P+P+f+F+p+P+P'

Try it online!
Gol><>
"rpH'''rpp>o<def n(x):global l;r=p+p+f+F+P+q+(p+P)*(l-x)+Q+P if x<l else p+p+f+F+P+(p+P)*(x-l)+P;l=x;return r;''a''p=chr(40);P=chr(41);q=chr(91);Q=chr(93);f=chr(123);F=chr(125);l=4;print p+p+p+p+p+p+P+p+P+p+P+P+f+F+P+f+F+p+P+P+f+F+P+f+F+P,str().join(map(n,map(lambda x:ord(x)-48,str().join(map(lambda c:`600`+(str(c-99).zfill(2)+`99500`.zfill(10) if c>99 else str(c).zfill(2)+`500`),[40,102,61,95,61,62,123,113,61,40,99,61,83,116,114,105,110,103,46,102,114,111,109,67,104,97,114,67,111,100,101,41,40,51,57,41,59,81,61,99,40,51,52,41,59,98,61,99,40,57,54,41,59,120,61,48,59,99,111,110,115,111,108,101,46,108,111,103,40,81,43,91,46,46,46,96,36,123,81,125,57,57,43,38,59,55,53,42,49,45,108,50,58,56,45,38,111,64,114,112,72,36,123,113,125,36,123,113,43,113,125,114,112,112,62,111,60,100,101,102,32,110,40,120,41,58,103,108,111,98,97,108,32,108,59,114,61,112,43,112,43,102,43,70,43,80,43,113,43,40,112,43,80,41,42,40,108,45,120,41,43,81,43,80,32,105,102,32,120,60,108,32,101,108,115,101,32,112,43,112,43,102,43,70,43,80,43,40,112,43,80,41,42,40,120,45,108,41,43,80,59,108,61,120,59,114,101,116,117,114,110,32,114,59,39,39,97,39,39,112,61,99,104,114,40,52,48,41,59,80,61,99,104,114,40,52,49,41,59,113,61,99,104,114,40,57,49,41,59,81,61,99,104,114,40,57,51,41,59,102,61,99,104,114,40,49,50,51,41,59,70,61,99,104,114,40,49,50,53,41,59,108,61,52,59,112,114,105,110,116,32,112,43,112,43,112,43,112,43,112,43,112,43,80,43,112,43,80,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,80,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,110,44,109,97,112,40,108,97,109,98,100,97,32,120,58,111,114,100,40,120,41,45,52,56,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,108,97,109,98,100,97,32,99,58,36,123,98,125,54,48,48,36,123,98,125,43,40,115,116,114,40,99,45,57,57,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,57,57,53,48,48,36,123,98,125,46,122,102,105,108,108,40,49,48,41,32,105,102,32,99,62,57,57,32,101,108,115,101,32,115,116,114,40,99,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,53,48,48,36,123,98,125,41,44,91,96,43,91,46,46,46,96,40,102,61,36,123,102,125,41,40,41,96,93,46,109,97,112,40,99,61,62,99,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,96,93,41,41,91,58,58,45,49,93,43,36,123,98,125,57,57,57,57,54,36,123,98,125,41,41,41,44,36,123,91,46,46,46,39,112,112,112,112,112,112,112,80,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,80,112,112,80,112,80,80,102,70,112,80,80,39,93,46,106,111,105,110,96,43,96,125,36,123,113,125,96,93,46,109,97,112,40,115,61,62,99,40,52,51,41,46,114,101,112,101,97,116,40,77,97,116,104,46,109,97,120,40,45,120,43,115,46,99,104,97,114,67,111,100,101,65,116,40,41,44,48,41,41,43,99,40,52,53,41,46,114,101,112,101,97,116,40,77,97,116,104,46,109,97,120,40,120,45,40,120,61,115,46,99,104,97,114,67,111,100,101,65,116,40,41,41,44,48,41,41,43,99,40,52,54,41,41,46,106,111,105,110,40,99,40,41,41,46,109,97,116,99,104,40,47,46,123,49,44,50,53,51,125,47,103,41,46,106,111,105,110,40,99,40,49,48,41,43,81,41,41,125,41,40,41]))[::-1]+`99996`))),p+p+p+p+p+p+p+P+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+P+p+p+P+p+P+P+f+F+p+P+P'

Try it online!
RAD
'''rpp>o<def n(x):global l;r=p+p+f+F+P+q+(p+P)*(l-x)+Q+P if x<l else p+p+f+F+P+(p+P)*(x-l)+P;l=x;return r;''a''p=chr(40);P=chr(41);q=chr(91);Q=chr(93);f=chr(123);F=chr(125);l=4;print p+p+p+p+p+p+P+p+P+p+P+P+f+F+P+f+F+p+P+P+f+F+P+f+F+P,str().join(map(n,map(lambda x:ord(x)-48,str().join(map(lambda c:`600`+(str(c-99).zfill(2)+`99500`.zfill(10) if c>99 else str(c).zfill(2)+`500`),[40,102,61,95,61,62,123,113,61,40,99,61,83,116,114,105,110,103,46,102,114,111,109,67,104,97,114,67,111,100,101,41,40,51,57,41,59,81,61,99,40,51,52,41,59,98,61,99,40,57,54,41,59,120,61,48,59,99,111,110,115,111,108,101,46,108,111,103,40,81,43,91,46,46,46,96,36,123,81,125,57,57,43,38,59,55,53,42,49,45,108,50,58,56,45,38,111,64,114,112,72,36,123,113,125,36,123,113,43,113,125,114,112,112,62,111,60,100,101,102,32,110,40,120,41,58,103,108,111,98,97,108,32,108,59,114,61,112,43,112,43,102,43,70,43,80,43,113,43,40,112,43,80,41,42,40,108,45,120,41,43,81,43,80,32,105,102,32,120,60,108,32,101,108,115,101,32,112,43,112,43,102,43,70,43,80,43,40,112,43,80,41,42,40,120,45,108,41,43,80,59,108,61,120,59,114,101,116,117,114,110,32,114,59,39,39,97,39,39,112,61,99,104,114,40,52,48,41,59,80,61,99,104,114,40,52,49,41,59,113,61,99,104,114,40,57,49,41,59,81,61,99,104,114,40,57,51,41,59,102,61,99,104,114,40,49,50,51,41,59,70,61,99,104,114,40,49,50,53,41,59,108,61,52,59,112,114,105,110,116,32,112,43,112,43,112,43,112,43,112,43,112,43,80,43,112,43,80,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,80,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,110,44,109,97,112,40,108,97,109,98,100,97,32,120,58,111,114,100,40,120,41,45,52,56,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,108,97,109,98,100,97,32,99,58,36,123,98,125,54,48,48,36,123,98,125,43,40,115,116,114,40,99,45,57,57,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,57,57,53,48,48,36,123,98,125,46,122,102,105,108,108,40,49,48,41,32,105,102,32,99,62,57,57,32,101,108,115,101,32,115,116,114,40,99,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,53,48,48,36,123,98,125,41,44,91,96,43,91,46,46,46,96,40,102,61,36,123,102,125,41,40,41,96,93,46,109,97,112,40,99,61,62,99,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,96,93,41,41,91,58,58,45,49,93,43,36,123,98,125,57,57,57,57,54,36,123,98,125,41,41,41,44,36,123,91,46,46,46,39,112,112,112,112,112,112,112,80,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,80,112,112,80,112,80,80,102,70,112,80,80,39,93,46,106,111,105,110,96,43,96,125,36,123,113,125,96,93,46,109,97,112,40,115,61,62,99,40,52,51,41,46,114,101,112,101,97,116,40,77,97,116,104,46,109,97,120,40,45,120,43,115,46,99,104,97,114,67,111,100,101,65,116,40,41,44,48,41,41,43,99,40,52,53,41,46,114,101,112,101,97,116,40,77,97,116,104,46,109,97,120,40,120,45,40,120,61,115,46,99,104,97,114,67,111,100,101,65,116,40,41,41,44,48,41,41,43,99,40,52,54,41,41,46,106,111,105,110,40,99,40,41,41,46,109,97,116,99,104,40,47,46,123,49,44,50,53,51,125,47,103,41,46,106,111,105,110,40,99,40,49,48,41,43,81,41,41,125,41,40,41]))[::-1]+`99996`))),p+p+p+p+p+p+p+P+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+P+p+p+P+p+P+P+f+F+p+P+P'

Try it online!
><>
'rpp>o<def n(x):global l;r=p+p+f+F+P+q+(p+P)*(l-x)+Q+P if x<l else p+p+f+F+P+(p+P)*(x-l)+P;l=x;return r;'a'p=chr(40);P=chr(41);q=chr(91);Q=chr(93);f=chr(123);F=chr(125);l=4;print p+p+p+p+p+p+P+p+P+p+P+P+f+F+P+f+F+p+P+P+f+F+P+f+F+P,str().join(map(n,map(lambda x:ord(x)-48,str().join(map(lambda c:`600`+(str(c-99).zfill(2)+`99500`.zfill(10) if c>99 else str(c).zfill(2)+`500`),[40,102,61,95,61,62,123,113,61,40,99,61,83,116,114,105,110,103,46,102,114,111,109,67,104,97,114,67,111,100,101,41,40,51,57,41,59,81,61,99,40,51,52,41,59,98,61,99,40,57,54,41,59,120,61,48,59,99,111,110,115,111,108,101,46,108,111,103,40,81,43,91,46,46,46,96,36,123,81,125,57,57,43,38,59,55,53,42,49,45,108,50,58,56,45,38,111,64,114,112,72,36,123,113,125,36,123,113,43,113,125,114,112,112,62,111,60,100,101,102,32,110,40,120,41,58,103,108,111,98,97,108,32,108,59,114,61,112,43,112,43,102,43,70,43,80,43,113,43,40,112,43,80,41,42,40,108,45,120,41,43,81,43,80,32,105,102,32,120,60,108,32,101,108,115,101,32,112,43,112,43,102,43,70,43,80,43,40,112,43,80,41,42,40,120,45,108,41,43,80,59,108,61,120,59,114,101,116,117,114,110,32,114,59,39,39,97,39,39,112,61,99,104,114,40,52,48,41,59,80,61,99,104,114,40,52,49,41,59,113,61,99,104,114,40,57,49,41,59,81,61,99,104,114,40,57,51,41,59,102,61,99,104,114,40,49,50,51,41,59,70,61,99,104,114,40,49,50,53,41,59,108,61,52,59,112,114,105,110,116,32,112,43,112,43,112,43,112,43,112,43,112,43,80,43,112,43,80,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,80,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,110,44,109,97,112,40,108,97,109,98,100,97,32,120,58,111,114,100,40,120,41,45,52,56,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,108,97,109,98,100,97,32,99,58,36,123,98,125,54,48,48,36,123,98,125,43,40,115,116,114,40,99,45,57,57,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,57,57,53,48,48,36,123,98,125,46,122,102,105,108,108,40,49,48,41,32,105,102,32,99,62,57,57,32,101,108,115,101,32,115,116,114,40,99,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,53,48,48,36,123,98,125,41,44,91,96,43,91,46,46,46,96,40,102,61,36,123,102,125,41,40,41,96,93,46,109,97,112,40,99,61,62,99,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,96,93,41,41,91,58,58,45,49,93,43,36,123,98,125,57,57,57,57,54,36,123,98,125,41,41,41,44,36,123,91,46,46,46,39,112,112,112,112,112,112,112,80,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,80,112,112,80,112,80,80,102,70,112,80,80,39,93,46,106,111,105,110,96,43,96,125,36,123,113,125,96,93,46,109,97,112,40,115,61,62,99,40,52,51,41,46,114,101,112,101,97,116,40,77,97,116,104,46,109,97,120,40,45,120,43,115,46,99,104,97,114,67,111,100,101,65,116,40,41,44,48,41,41,43,99,40,52,53,41,46,114,101,112,101,97,116,40,77,97,116,104,46,109,97,120,40,120,45,40,120,61,115,46,99,104,97,114,67,111,100,101,65,116,40,41,41,44,48,41,41,43,99,40,52,54,41,41,46,106,111,105,110,40,99,40,41,41,46,109,97,116,99,104,40,47,46,123,49,44,50,53,51,125,47,103,41,46,106,111,105,110,40,99,40,49,48,41,43,81,41,41,125,41,40,41]))[::-1]+`99996`))),p+p+p+p+p+p+p+P+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+P+p+p+P+p+P+P+f+F+p+P+P

Try it online!
Python 2
def n(x):global l;r=p+p+f+F+P+q+(p+P)*(l-x)+Q+P if x<l else p+p+f+F+P+(p+P)*(x-l)+P;l=x;return r;
p=chr(40);P=chr(41);q=chr(91);Q=chr(93);f=chr(123);F=chr(125);l=4;print p+p+p+p+p+p+P+p+P+p+P+P+f+F+P+f+F+p+P+P+f+F+P+f+F+P,str().join(map(n,map(lambda x:ord(x)-48,str().join(map(lambda c:`600`+(str(c-99).zfill(2)+`99500`.zfill(10) if c>99 else str(c).zfill(2)+`500`),[40,102,61,95,61,62,123,113,61,40,99,61,83,116,114,105,110,103,46,102,114,111,109,67,104,97,114,67,111,100,101,41,40,51,57,41,59,81,61,99,40,51,52,41,59,98,61,99,40,57,54,41,59,120,61,48,59,99,111,110,115,111,108,101,46,108,111,103,40,81,43,91,46,46,46,96,36,123,81,125,57,57,43,38,59,55,53,42,49,45,108,50,58,56,45,38,111,64,114,112,72,36,123,113,125,36,123,113,43,113,125,114,112,112,62,111,60,100,101,102,32,110,40,120,41,58,103,108,111,98,97,108,32,108,59,114,61,112,43,112,43,102,43,70,43,80,43,113,43,40,112,43,80,41,42,40,108,45,120,41,43,81,43,80,32,105,102,32,120,60,108,32,101,108,115,101,32,112,43,112,43,102,43,70,43,80,43,40,112,43,80,41,42,40,120,45,108,41,43,80,59,108,61,120,59,114,101,116,117,114,110,32,114,59,39,39,97,39,39,112,61,99,104,114,40,52,48,41,59,80,61,99,104,114,40,52,49,41,59,113,61,99,104,114,40,57,49,41,59,81,61,99,104,114,40,57,51,41,59,102,61,99,104,114,40,49,50,51,41,59,70,61,99,104,114,40,49,50,53,41,59,108,61,52,59,112,114,105,110,116,32,112,43,112,43,112,43,112,43,112,43,112,43,80,43,112,43,80,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,80,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,110,44,109,97,112,40,108,97,109,98,100,97,32,120,58,111,114,100,40,120,41,45,52,56,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,108,97,109,98,100,97,32,99,58,36,123,98,125,54,48,48,36,123,98,125,43,40,115,116,114,40,99,45,57,57,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,57,57,53,48,48,36,123,98,125,46,122,102,105,108,108,40,49,48,41,32,105,102,32,99,62,57,57,32,101,108,115,101,32,115,116,114,40,99,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,53,48,48,36,123,98,125,41,44,91,96,43,91,46,46,46,96,40,102,61,36,123,102,125,41,40,41,96,93,46,109,97,112,40,99,61,62,99,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,96,93,41,41,91,58,58,45,49,93,43,36,123,98,125,57,57,57,57,54,36,123,98,125,41,41,41,44,36,123,91,46,46,46,39,112,112,112,112,112,112,112,80,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,80,112,112,80,112,80,80,102,70,112,80,80,39,93,46,106,111,105,110,96,43,96,125,36,123,113,125,96,93,46,109,97,112,40,115,61,62,99,40,52,51,41,46,114,101,112,101,97,116,40,77,97,116,104,46,109,97,120,40,45,120,43,115,46,99,104,97,114,67,111,100,101,65,116,40,41,44,48,41,41,43,99,40,52,53,41,46,114,101,112,101,97,116,40,77,97,116,104,46,109,97,120,40,120,45,40,120,61,115,46,99,104,97,114,67,111,100,101,65,116,40,41,41,44,48,41,41,43,99,40,52,54,41,41,46,106,111,105,110,40,99,40,41,41,46,109,97,116,99,104,40,47,46,123,49,44,50,53,51,125,47,103,41,46,106,111,105,110,40,99,40,49,48,41,43,81,41,41,125,41,40,41]))[::-1]+`99996`))),p+p+p+p+p+p+p+P+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+P+p+p+P+p+P+P+f+F+p+P+P

Try it online!
Brain-Flak
Try it online!
4
3.[encoded data, 8374 characters]

Try it online!

3. JavaScript → Python 2 → Foo
JavaScript
Classic JS quine. This is a full program which outputs to console:
(f=_=>console.log(`print(${String.fromCharCode(39)}${String.fromCharCode(34)}(f=${f})()${String.fromCharCode(34)}${String.fromCharCode(39)})`))()

Try it online!
Python 2
Python code basically prints out the JS code with quotes:
print('"(f=_=>console.log(`print(${String.fromCharCode(39)}${String.fromCharCode(34)}(f=${f})()${String.fromCharCode(34)}${String.fromCharCode(39)})`))()"')

Try it online!
Foo
Foo code is JS code with quotes:
"(f=_=>console.log(`print(${String.fromCharCode(39)}${String.fromCharCode(34)}(f=${f})()${String.fromCharCode(34)}${String.fromCharCode(39)})`))()"

Try it online!

Why not e.g. String.fromCharCode(39,34) to save on the repeated invocations?

@ETHproductions I.. actually had no idea you could do that >_<

Or at least String.fromCharCode(39)+String.fromCharCode(34) to save a little bit ;-)

1. Foo
Foo
A simple Foo quine:
>&41>&60>&99>&36>&40>&60>&41>&62>&105>&36>&34>&38>&62>&34>&40>&62>&41>&60>&40(<)>(">&"$i>)<($c<)

Try it online!

2. Python 2 → Foo
i used the basic python quine, then added the quotes
python:
_='_=%r;print chr(34)+_%%_+chr(34)';print chr(34)+_%_+chr(34)

Try it online!
foo:

"_='_=%r;print chr(34)+_%%_+chr(34)';print chr(34)+_%_+chr(34)"

Try it online!

5. ><> → JavaScript → brainfuck → Python 2 → Foo
Obligatory brainfuck answer.
><>
'rpp>o<(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log([...`print(${q+Q+s+q}rpp>o<(f=${f})()${Q+q})`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join())})()

Try it online!
JavaScript
(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log([...`print(${q+Q+s+q}rpp>o<(f=${f})()${Q+q})`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join())})()

Try it online!
brainfuck
[encoded data, 15021 characters]

Try it online!
Python 2
print('"\'rpp>o<(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log([...`print(${q+Q+s+q}rpp>o<(f=${f})()${Q+q})`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join())})()"')

Try it online!
Foo
"'rpp>o<(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log([...`print(${q+Q+s+q}rpp>o<(f=${f})()${Q+q})`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join())})()"

Try it online!

9. JavaScript → Foo → Brainfuck → Wumpus → RAD → ><> → Python 2 → Brain-Flak → 4
This... was.. fun.
No idea why I decided that 4 should be added, no idea why I remade the entire thing (of course, copy-pasting stuff around), but I did it :D
JavaScript
(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);b=c(96);console.log(Q+[...`${Q}76+&;l2:6-&o@${q}${q+q}rpp>o<def n(x):global l;r=p+p+f+F+P+q+(p+P)*(l-x)+Q+P if x<l else p+p+f+F+P+(p+P)*(x-l)+P;l=x;return r;''a''p=chr(40);P=chr(41);q=chr(91);Q=chr(93);f=chr(123);F=chr(125);l=4;print p+p+p+p+p+p+P+p+P+p+P+P+f+F+P+f+F+p+P+P+f+F+P+f+F+P,map(n,map(lambda x:ord(x)-48,str().join(map(lambda c:${b}600${b}+(str(c-99).zfill(2)+${b}99500${b}.zfill(10) if c>99 else str(c).zfill(2)+${b}500${b}),[`+[...`(f=${f})()`].map(c=>c.charCodeAt())+`]))[::-1]+${b}99996${b})),${[...'pppppppPpPPfFpPPfFpPPfFpPPfFPppPpPPfFpPP'].join`+`}${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join().match(/.{1,253}/g).join(c(10)+Q))})()

Try it online!
Since the output is too big for TIO to return, Here's a tester that cycles trough all the languages.
Foo
Try it online!
brainfuck
Try it online!
Wumpus
"76+&;l2:6-&o@'''rpp>o<def n(x):global l;r=p+p+f+F+P+q+(p+P)*(l-x)+Q+P if x<l else p+p+f+F+P+(p+P)*(x-l)+P;l=x;return r;''a''p=chr(40);P=chr(41);q=chr(91);Q=chr(93);f=chr(123);F=chr(125);l=4;print p+p+p+p+p+p+P+p+P+p+P+P+f+F+P+f+F+p+P+P+f+F+P+f+F+P,map(n,map(lambda x:ord(x)-48,str().join(map(lambda c:`600`+(str(c-99).zfill(2)+`99500`.zfill(10) if c>99 else str(c).zfill(2)+`500`),[40,102,61,95,61,62,123,113,61,40,99,61,83,116,114,105,110,103,46,102,114,111,109,67,104,97,114,67,111,100,101,41,40,51,57,41,59,81,61,99,40,51,52,41,59,98,61,99,40,57,54,41,59,99,111,110,115,111,108,101,46,108,111,103,40,81,43,91,46,46,46,96,36,123,81,125,55,54,43,38,59,108,50,58,54,45,38,111,64,36,123,113,125,36,123,113,43,113,125,114,112,112,62,111,60,100,101,102,32,110,40,120,41,58,103,108,111,98,97,108,32,108,59,114,61,112,43,112,43,102,43,70,43,80,43,113,43,40,112,43,80,41,42,40,108,45,120,41,43,81,43,80,32,105,102,32,120,60,108,32,101,108,115,101,32,112,43,112,43,102,43,70,43,80,43,40,112,43,80,41,42,40,120,45,108,41,43,80,59,108,61,120,59,114,101,116,117,114,110,32,114,59,39,39,97,39,39,112,61,99,104,114,40,52,48,41,59,80,61,99,104,114,40,52,49,41,59,113,61,99,104,114,40,57,49,41,59,81,61,99,104,114,40,57,51,41,59,102,61,99,104,114,40,49,50,51,41,59,70,61,99,104,114,40,49,50,53,41,59,108,61,52,59,112,114,105,110,116,32,112,43,112,43,112,43,112,43,112,43,112,43,80,43,112,43,80,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,80,44,109,97,112,40,110,44,109,97,112,40,108,97,109,98,100,97,32,120,58,111,114,100,40,120,41,45,52,56,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,108,97,109,98,100,97,32,99,58,36,123,98,125,54,48,48,36,123,98,125,43,40,115,116,114,40,99,45,57,57,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,57,57,53,48,48,36,123,98,125,46,122,102,105,108,108,40,49,48,41,32,105,102,32,99,62,57,57,32,101,108,115,101,32,115,116,114,40,99,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,53,48,48,36,123,98,125,41,44,91,96,43,91,46,46,46,96,40,102,61,36,123,102,125,41,40,41,96,93,46,109,97,112,40,99,61,62,99,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,96,93,41,41,91,58,58,45,49,93,43,36,123,98,125,57,57,57,57,54,36,123,98,125,41,41,44,36,123,91,46,46,46,39,112,112,112,112,112,112,112,80,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,80,112,112,80,112,80,80,102,70,112,80,80,39,93,46,106,111,105,110,96,43,96,125,36,123,113,125,96,93,46,109,97,112,40,115,61,62,99,40,52,51,41,46,114,101,112,101,97,116,40,115,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,99,40,52,54,41,41,46,106,111,105,110,40,41,46,109,97,116,99,104,40,47,46,123,49,44,50,53,51,125,47,103,41,46,106,111,105,110,40,99,40,49,48,41,43,81,41,41,125,41,40,41]))[::-1]+`99996`)),p+p+p+p+p+p+p+P+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+P+p+p+P+p+P+P+f+F+p+P+P'

Try it online!
RAD
'''rpp>o<def n(x):global l;r=p+p+f+F+P+q+(p+P)*(l-x)+Q+P if x<l else p+p+f+F+P+(p+P)*(x-l)+P;l=x;return r;''a''p=chr(40);P=chr(41);q=chr(91);Q=chr(93);f=chr(123);F=chr(125);l=4;print p+p+p+p+p+p+P+p+P+p+P+P+f+F+P+f+F+p+P+P+f+F+P+f+F+P,map(n,map(lambda x:ord(x)-48,str().join(map(lambda c:`600`+(str(c-99).zfill(2)+`99500`.zfill(10) if c>99 else str(c).zfill(2)+`500`),[40,102,61,95,61,62,123,113,61,40,99,61,83,116,114,105,110,103,46,102,114,111,109,67,104,97,114,67,111,100,101,41,40,51,57,41,59,81,61,99,40,51,52,41,59,98,61,99,40,57,54,41,59,99,111,110,115,111,108,101,46,108,111,103,40,81,43,91,46,46,46,96,36,123,81,125,55,54,43,38,59,108,50,58,54,45,38,111,64,36,123,113,125,36,123,113,43,113,125,114,112,112,62,111,60,100,101,102,32,110,40,120,41,58,103,108,111,98,97,108,32,108,59,114,61,112,43,112,43,102,43,70,43,80,43,113,43,40,112,43,80,41,42,40,108,45,120,41,43,81,43,80,32,105,102,32,120,60,108,32,101,108,115,101,32,112,43,112,43,102,43,70,43,80,43,40,112,43,80,41,42,40,120,45,108,41,43,80,59,108,61,120,59,114,101,116,117,114,110,32,114,59,39,39,97,39,39,112,61,99,104,114,40,52,48,41,59,80,61,99,104,114,40,52,49,41,59,113,61,99,104,114,40,57,49,41,59,81,61,99,104,114,40,57,51,41,59,102,61,99,104,114,40,49,50,51,41,59,70,61,99,104,114,40,49,50,53,41,59,108,61,52,59,112,114,105,110,116,32,112,43,112,43,112,43,112,43,112,43,112,43,80,43,112,43,80,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,80,44,109,97,112,40,110,44,109,97,112,40,108,97,109,98,100,97,32,120,58,111,114,100,40,120,41,45,52,56,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,108,97,109,98,100,97,32,99,58,36,123,98,125,54,48,48,36,123,98,125,43,40,115,116,114,40,99,45,57,57,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,57,57,53,48,48,36,123,98,125,46,122,102,105,108,108,40,49,48,41,32,105,102,32,99,62,57,57,32,101,108,115,101,32,115,116,114,40,99,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,53,48,48,36,123,98,125,41,44,91,96,43,91,46,46,46,96,40,102,61,36,123,102,125,41,40,41,96,93,46,109,97,112,40,99,61,62,99,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,96,93,41,41,91,58,58,45,49,93,43,36,123,98,125,57,57,57,57,54,36,123,98,125,41,41,44,36,123,91,46,46,46,39,112,112,112,112,112,112,112,80,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,80,112,112,80,112,80,80,102,70,112,80,80,39,93,46,106,111,105,110,96,43,96,125,36,123,113,125,96,93,46,109,97,112,40,115,61,62,99,40,52,51,41,46,114,101,112,101,97,116,40,115,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,99,40,52,54,41,41,46,106,111,105,110,40,41,46,109,97,116,99,104,40,47,46,123,49,44,50,53,51,125,47,103,41,46,106,111,105,110,40,99,40,49,48,41,43,81,41,41,125,41,40,41]))[::-1]+`99996`)),p+p+p+p+p+p+p+P+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+P+p+p+P+p+P+P+f+F+p+P+P'

Try it online!
><>
'rpp>o<def n(x):global l;r=p+p+f+F+P+q+(p+P)*(l-x)+Q+P if x<l else p+p+f+F+P+(p+P)*(x-l)+P;l=x;return r;'a'p=chr(40);P=chr(41);q=chr(91);Q=chr(93);f=chr(123);F=chr(125);l=4;print p+p+p+p+p+p+P+p+P+p+P+P+f+F+P+f+F+p+P+P+f+F+P+f+F+P,map(n,map(lambda x:ord(x)-48,str().join(map(lambda c:`600`+(str(c-99).zfill(2)+`99500`.zfill(10) if c>99 else str(c).zfill(2)+`500`),[40,102,61,95,61,62,123,113,61,40,99,61,83,116,114,105,110,103,46,102,114,111,109,67,104,97,114,67,111,100,101,41,40,51,57,41,59,81,61,99,40,51,52,41,59,98,61,99,40,57,54,41,59,99,111,110,115,111,108,101,46,108,111,103,40,81,43,91,46,46,46,96,36,123,81,125,55,54,43,38,59,108,50,58,54,45,38,111,64,36,123,113,125,36,123,113,43,113,125,114,112,112,62,111,60,100,101,102,32,110,40,120,41,58,103,108,111,98,97,108,32,108,59,114,61,112,43,112,43,102,43,70,43,80,43,113,43,40,112,43,80,41,42,40,108,45,120,41,43,81,43,80,32,105,102,32,120,60,108,32,101,108,115,101,32,112,43,112,43,102,43,70,43,80,43,40,112,43,80,41,42,40,120,45,108,41,43,80,59,108,61,120,59,114,101,116,117,114,110,32,114,59,39,39,97,39,39,112,61,99,104,114,40,52,48,41,59,80,61,99,104,114,40,52,49,41,59,113,61,99,104,114,40,57,49,41,59,81,61,99,104,114,40,57,51,41,59,102,61,99,104,114,40,49,50,51,41,59,70,61,99,104,114,40,49,50,53,41,59,108,61,52,59,112,114,105,110,116,32,112,43,112,43,112,43,112,43,112,43,112,43,80,43,112,43,80,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,80,44,109,97,112,40,110,44,109,97,112,40,108,97,109,98,100,97,32,120,58,111,114,100,40,120,41,45,52,56,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,108,97,109,98,100,97,32,99,58,36,123,98,125,54,48,48,36,123,98,125,43,40,115,116,114,40,99,45,57,57,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,57,57,53,48,48,36,123,98,125,46,122,102,105,108,108,40,49,48,41,32,105,102,32,99,62,57,57,32,101,108,115,101,32,115,116,114,40,99,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,53,48,48,36,123,98,125,41,44,91,96,43,91,46,46,46,96,40,102,61,36,123,102,125,41,40,41,96,93,46,109,97,112,40,99,61,62,99,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,96,93,41,41,91,58,58,45,49,93,43,36,123,98,125,57,57,57,57,54,36,123,98,125,41,41,44,36,123,91,46,46,46,39,112,112,112,112,112,112,112,80,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,80,112,112,80,112,80,80,102,70,112,80,80,39,93,46,106,111,105,110,96,43,96,125,36,123,113,125,96,93,46,109,97,112,40,115,61,62,99,40,52,51,41,46,114,101,112,101,97,116,40,115,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,99,40,52,54,41,41,46,106,111,105,110,40,41,46,109,97,116,99,104,40,47,46,123,49,44,50,53,51,125,47,103,41,46,106,111,105,110,40,99,40,49,48,41,43,81,41,41,125,41,40,41]))[::-1]+`99996`)),p+p+p+p+p+p+p+P+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+P+p+p+P+p+P+P+f+F+p+P+P

><> outputs a newline in the middle with 'a' so the python function would be separated from the rest of the code.
Try it online!
Python 2
def n(x):global l;r=p+p+f+F+P+q+(p+P)*(l-x)+Q+P if x<l else p+p+f+F+P+(p+P)*(x-l)+P;l=x;return r;
p=chr(40);P=chr(41);q=chr(91);Q=chr(93);f=chr(123);F=chr(125);l=4;print p+p+p+p+p+p+P+p+P+p+P+P+f+F+P+f+F+p+P+P+f+F+P+f+F+P,map(n,map(lambda x:ord(x)-48,str().join(map(lambda c:`600`+(str(c-99).zfill(2)+`99500`.zfill(10) if c>99 else str(c).zfill(2)+`500`),[40,102,61,95,61,62,123,113,61,40,99,61,83,116,114,105,110,103,46,102,114,111,109,67,104,97,114,67,111,100,101,41,40,51,57,41,59,81,61,99,40,51,52,41,59,98,61,99,40,57,54,41,59,99,111,110,115,111,108,101,46,108,111,103,40,81,43,91,46,46,46,96,36,123,81,125,55,54,43,38,59,108,50,58,54,45,38,111,64,36,123,113,125,36,123,113,43,113,125,114,112,112,62,111,60,100,101,102,32,110,40,120,41,58,103,108,111,98,97,108,32,108,59,114,61,112,43,112,43,102,43,70,43,80,43,113,43,40,112,43,80,41,42,40,108,45,120,41,43,81,43,80,32,105,102,32,120,60,108,32,101,108,115,101,32,112,43,112,43,102,43,70,43,80,43,40,112,43,80,41,42,40,120,45,108,41,43,80,59,108,61,120,59,114,101,116,117,114,110,32,114,59,39,39,97,39,39,112,61,99,104,114,40,52,48,41,59,80,61,99,104,114,40,52,49,41,59,113,61,99,104,114,40,57,49,41,59,81,61,99,104,114,40,57,51,41,59,102,61,99,104,114,40,49,50,51,41,59,70,61,99,104,114,40,49,50,53,41,59,108,61,52,59,112,114,105,110,116,32,112,43,112,43,112,43,112,43,112,43,112,43,80,43,112,43,80,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,112,43,80,43,80,43,102,43,70,43,80,43,102,43,70,43,80,44,109,97,112,40,110,44,109,97,112,40,108,97,109,98,100,97,32,120,58,111,114,100,40,120,41,45,52,56,44,115,116,114,40,41,46,106,111,105,110,40,109,97,112,40,108,97,109,98,100,97,32,99,58,36,123,98,125,54,48,48,36,123,98,125,43,40,115,116,114,40,99,45,57,57,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,57,57,53,48,48,36,123,98,125,46,122,102,105,108,108,40,49,48,41,32,105,102,32,99,62,57,57,32,101,108,115,101,32,115,116,114,40,99,41,46,122,102,105,108,108,40,50,41,43,36,123,98,125,53,48,48,36,123,98,125,41,44,91,96,43,91,46,46,46,96,40,102,61,36,123,102,125,41,40,41,96,93,46,109,97,112,40,99,61,62,99,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,96,93,41,41,91,58,58,45,49,93,43,36,123,98,125,57,57,57,57,54,36,123,98,125,41,41,44,36,123,91,46,46,46,39,112,112,112,112,112,112,112,80,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,112,80,80,102,70,80,112,112,80,112,80,80,102,70,112,80,80,39,93,46,106,111,105,110,96,43,96,125,36,123,113,125,96,93,46,109,97,112,40,115,61,62,99,40,52,51,41,46,114,101,112,101,97,116,40,115,46,99,104,97,114,67,111,100,101,65,116,40,41,41,43,99,40,52,54,41,41,46,106,111,105,110,40,41,46,109,97,116,99,104,40,47,46,123,49,44,50,53,51,125,47,103,41,46,106,111,105,110,40,99,40,49,48,41,43,81,41,41,125,41,40,41]))[::-1]+`99996`)),p+p+p+p+p+p+p+P+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+p+P+P+f+F+P+p+p+P+p+P+P+f+F+p+P+P

Try it online!
Python generates the brain-flak somewhat optimized, reusing the previous item on the stack, because otherwise the brain-flak code would be around a megabyte..
Brain-Flak
Try it online!
4
3.[encoded data, 7431 characters]
Try it online!

4. ><> → JavaScript → Python 2 → Foo
><>
'rpp>o<(f=_=>console.log(`print(${String.fromCharCode(39,34,92,39)}rpp>o<(f=${f})()${String.fromCharCode(34,39)})`))()

Try it online!
I've added the classic wrapping string literal, appending 'rpp>o< to the start, and editing it into the center part too.
JavaScript (Node.js)
(f=_=>console.log(`print(${(a=String.fromCharCode)(39,34,92,39)}rpp>o<(f=${f})()${a(34,39)})`))()

Try it online!
I've shortened the String.fromCharCode part as per comments on the last answer. I know this challenge isn't actually code-golf, but it makes me feel better.
Python 2
print('"\'rpp>o<(f=_=>console.log(`print(${(a=String.fromCharCode)(39,34,92,39)}rpp>o<(f=${f})()${a(34,39)})`))()"')

Try it online!
Added the \' for the start of the ><> quine.
Foo
"'rpp>o<(f=_=>console.log(`print(${(a=String.fromCharCode)(39,34,92,39)}rpp>o<(f=${f})()${a(34,39)})`))()"

Try it online!

6. ><> → JavaScript → brainfuck → Python 2 → Brain-Flak → Foo
Obligatory Brain-Flak answer.
><>
'rpp>o<(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log([...`print map(lambda x:${q}(${q}+ord(x)*${q}()${q}+${q})${q},${q+Q+s+q}rpp>o<(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join())})()

Try it online!
JavaScript (Node.js)
(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log([...`print map(lambda x:${q}(${q}+ord(x)*${q}()${q}+${q})${q},${q+Q+s+q}rpp>o<(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join())})()

Try it online!
brainfuck
[encoded data, 24781 characters]

Try it online!
Python 2
print map(lambda x:'('+ord(x)*'()'+')','"\'rpp>o<(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log([...`print map(lambda x:${q}(${q}+ord(x)*${q}()${q}+${q})${q},${q+Q+s+q}rpp>o<(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join())})()"'),'{({}<>)<>}<>'

Try it online!
Brain-Flak
Try it online!
I've excluded the code since it's 41568 bytes and reaches the character limit of the answer. The code is similar to the brainfuck code and is in the format:
[
  '( ()*byte value )', Repeated for each character
] '{({}<>)<>}<>'      To reverse the stack

Foo
"'rpp>o<(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log([...`print map(lambda x:${q}(${q}+ord(x)*${q}()${q}+${q})${q},${q+Q+s+q}rpp>o<(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join())})()"

Try it online!

7. ><> → JavaScript → RAD → brainfuck → Python 2 → Brain-Flak → Foo
><>
'rpp>o<(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log(q+[...`print map(lambda x:${q}(${q}+ord(x)*${q}()${q}+${q})${q},${q+Q+s+q}rpp>o<(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join()+q)})()

Try it online!
JavaScript
(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log(q+[...`print map(lambda x:${q}(${q}+ord(x)*${q}()${q}+${q})${q},${q+Q+s+q}rpp>o<(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join()+q)})()

Try it online!
RAD
[encoded data, 25103 characters]

Try it online!
brainfuck
[encoded data, 25101 characters]

Try it online!
Python 2
print map(lambda x:'('+ord(x)*'()'+')','"\'rpp>o<(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log(q+[...`print map(lambda x:${q}(${q}+ord(x)*${q}()${q}+${q})${q},${q+Q+s+q}rpp>o<(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join()+q)})()"'),'{({}<>)<>}<>'

Try it online!
Brain-Flak
Try it online!
Foo
"'rpp>o<(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log(q+[...`print map(lambda x:${q}(${q}+ord(x)*${q}()${q}+${q})${q},${q+Q+s+q}rpp>o<(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join()+q)})()"

Try it online!

8. ><> → Wumpus → JavaScript → RAD → brainfuck → Python 2 → Brain-Flak → Foo
Adding in another 2D language, Wumpus.
><>
'rppp:1->o#13&;l2:6-&o@(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log(q+[...`print map(lambda x:(ord(x)*${q}()${q},),${q+Q+s+q}rppp:1->o#13&;l2:6-&o@${Q+s}n${Q}(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join()+q)})()

Try it online!
This now prints an extra " before the Wumpus code.
Wumpus
"#13&;l2:6-&o@(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log(q+[...`print map(lambda x:(ord(x)*${q}()${q},),${q+Q+s+q}rppp:1->o#13&;l2:6-&o@${Q+s}n${Q}(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join()+q)})()

Try it online!
Similar to the ><> quine, this wraps a string literal around the code and printsonly the javascript section
JavaScript (Node.js)
(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log(q+[...`print map(lambda x:(ord(x)*${q}()${q},),${q+Q+s+q}rppp:1->o#13&;l2:6-&o@${Q+s}n${Q}(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join()+q)})()

Try it online!
RAD
Try it online!
I'm excluding very long sections of code from the chain, so as to not fill up the answer.
brainfuck
Try it online!
Python 2
print map(lambda x:(ord(x)*'()',),'"\'rppp:1->o#13&;l2:6-&o@"\n"(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log(q+[...`print map(lambda x:(ord(x)*${q}()${q},),${q+Q+s+q}rppp:1->o#13&;l2:6-&o@${Q+s}n${Q}(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join()+q)})()"'),'{({}<>)<>}<>'

Try it online!
Brain-Flak
Try it online!
Foo
"'rppp:1->o#13&;l2:6-&o@"
"(f=_=>{q=(c=String.fromCharCode)(39);Q=c(34);s=c(92);console.log(q+[...`print map(lambda x:(ord(x)*${q}()${q},),${q+Q+s+q}rppp:1->o#13&;l2:6-&o@${Q+s}n${Q}(f=${f})()${Q+q}),${q}{({}<>)<>}<>${q}`].map(s=>c(43).repeat(s.charCodeAt())+c(46)).join()+q)})()"

Try it online!
This was actually the most annoying part of the code. Foo only supports string literals of 254 length for some reason, so I had to golf a bit and split up the Javascript from the 2D code to keep it short. The next person will probably have to split up the Javascript.

source: Stack Exchange

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

sort: votes


text:
Primality testing formula
Your goal is to determine whether a given number n is prime in the fewest bytes. But, your code must be a single Python 2 expression on numbers consisting of only

operators
the input variable n
integer constants
parentheses

No loops, no assignments, no built-in functions, only what's listed above. Yes, it's possible.
Operators
Here's a list of all operators in Python 2, which include arithmetic, bitwise, and logical operators:
+    adddition
-    minus or unary negation
*    multiplication
**   exponentiation, only with non-negative exponent
/    floor division
%    modulo
<<   bit shift left
>>   bit shift right
&    bitwise and
|    bitwise or
^    bitwise xor
~    bitwise not
<    less than
>    greater than
<=   less than or equals
>=   greater than or equals
==   equals
!=   does not equal

All intermediate values are integers (or False/True, which implicitly equals 0 and 1). Exponentiation may not be used with negative exponents, as this may produce floats. Note that / does floor-division, unlike Python 3, so // is not needed.
Even if you're not familiar with Python, the operators should be pretty intuitive. See this table for operator precedence and this section and below for a detailed specification of the grammar. You can run Python 2 on TIO.
I/O
Input: A positive integer n that's at least 2.
Output: 1 if n is prime, and 0 otherwise. True and False may also be used. Fewest bytes wins.
Since your code is an expression, it will be a snippet, expecting the input value stored as n, and evaluating to the output desired.
Your code must work for n arbitrarily large, system limits aside. Since Python's whole-number type is unbounded, there are no limits on the operators. Your code may take however long to run.

Maybe this should have the python tag?

43 bytes
(4**n+1)**n%4**n**2/n&2**(2*n*n+n)/-~2**n<1

Try it online!
The method is similar to Dennis' second (deleted) answer, but this answer is easier to be proved correct.
Proof
Short form
The most significant digit of (4**n+1)**n%4**n**2 in base \$2^n\$ that is not divisible by \$n\$ will make the next (less significant) digit in (4**n+1)**n%4**n**2/n nonzero (if that "next digit" is not in the fractional part), then a & with the bitmask 2**(2*n*n+n)/-~2**n is executed to check if any digit at odd position is nonzero.
Long form
Let \$[a_n,\dots,a_1,a_0]_b\$ be the number having that base \$b\$ representation, i.e., \$a_nb^n+\dots+a_1b^1+a_0b^0\$, and \$a_i\$ be the digit at "position" \$i\$ in base \$b\$ representation.

\$\texttt{2**(2*n*n+n)/-~2**n}
=\lfloor{2^{(2n+1)n}\over1+2^n}\rfloor
=\lfloor{4^{n^2}\times 2^n\over1+2^n}\rfloor
=\lfloor{{(4^{n^2}-1)\times 2^n\over1+2^n}
+{2^n\over1+2^n}}\rfloor
\$.

Because \$2^n\times{4^{n^2}-1\over1+2^n}
=2^n(2^n-1)\times{(4^n)^n-1\over4^n-1}
=[2^n-1,0,2^n-1,0,2^n-1,0]_{2^n}\$ (with \$n\$ \$2^n-1\$s) is an integer,
and \$\lfloor{2^n\over1+2^n}\rfloor=0\$,
2**(2*n*n+n)/-~2**n = \$[2^n-1,0,2^n-1,0,2^n-1,0]_{2^n}\$.
Next, consider
$$\begin{align}
\texttt{(4**n+1)**n}
&=(4^n+1)^n \\
&=\binom n04^{0n}+\binom n14^{1n}+\dots+\binom nn4^{n^2} \\
&=\left[\binom nn,0,\dots,0,\binom n1,0,\binom n0\right]_{2^n}
\end{align}$$
\$4^{n^2}=(2^n)^{2n}\$, so %4**n**2 will truncate the number to \$2n\$ last digits - that excludes the \$\binom nn\$ (which is 1) but include all other binomial coefficients.
About /n:

If \$n\$ is a prime, the result will be \$\left[\binom n{n-1}/n,0,\dots,0,\binom n1/n,0,0\right]_{2^n}\$. All digits at odd position are zero.
If \$n\$ is not a prime:
Let \$a\$ be the largest integer such that \$n\nmid\binom na\$ (\$n>a>0\$). Rewrite the dividend as
\$\left[\binom n{n-1},0,\binom n{n-2},0,\dots,\binom n{a+1},
    0,0,0,\dots,0,0,0\right]_{2^n} +
\left[\binom na,0,\binom n{a-1},0,\dots,\binom n0\right]_{2^n}\$
The first summand has all digits divisible by \$n\$, and the digit at position \$2a-1\$ zero.
The second summand has its most significant digit (at position \$2a\$) not divisible by \$n\$ and (the base) \$2^n>n\$, so the quotient when dividing that by \$n\$ would have the digit at position \$2a-1\$ nonzero.
Therefore, the final result ((4**n+1)**n%4**n**2/n) should have the digit (base \$2^n\$, of course) at position \$2a+1\$ nonzero.

Finally, the bitwise AND (&) performs a vectorized bitwise AND on the digits in base \$2^n\$ (because the base is a power of 2), and because \$a\texttt &0=0,a\texttt&(2^n-1)=a\$ for all \$0\le a<2^n\$, (4**n+1)**n%4**n**2/n&2**(2*n*n+n)/-~2**n is zero iff (4**n+1)**n%4**n**2/n has all digits in first \$n\$ odd positions zero - which is equivalent to \$n\$ being prime.

Would (4**n+1)**n%2**n**2/n&2**n**2/-~2**n<1 work?

If it's easy to prove correct, could you include the proof in the answer? We have MathJax now, so it's relatively easy to make proofs legible, and I can't see an obvious reason for the division by n not to cause unwanted interactions between the digits base 4**n.

"I have discovered a truly remarkable proof of this answer which this comment is too small to contain..."

@Dennis That should work, but it may make the (already long) proof longer, because it's necessary to consider odd and even n separately.

Suggestions for shortening the proof are welcome.

Nicely done! This is the same solution I had come up with. I found a couple of bytes can be cut with (4**n+1)**n%4**n**2/n<<n&4**n**2/-~2**n<1. I'm curious if this challenge is possible without bitwise operators.

Python 2, 56 bytes
n**(n*n-n)/(((2**n**n+1)**n**n>>n**n*~-n)%2**n**n)%n>n-2

Try it online!
This is a proof-of-concept that this challenge is doable with only arithmetic operators, in particular without bitwise |, &, or ^. The code uses bitwise and comparison operators only for golfing, and they can easily be replaced with arithmetic equivalents.
However, the solution is extremely slow, and I haven't been able to run \$n=6\$`, thanks to two-level exponents like \$2^{n^n}\$.
The main idea is to make an expression for the factorial \$n!\$, which lets us do a Wilson's Theorem primality test \$(n-1)! \mathbin{\%} n > n-2 \$ where \$ \mathbin{\%}\$ is the modulo operator.
We can make an expression for the binomial coefficient, which is made of factorials
$$\binom{m}{n} \ = \frac{m!}{n!(m-n)!}$$
But it's not clear how to extract just one of these factorials. The trick is to hammer apart \$n!\$ by making \$m\$ really huge.
$$\binom{m}{n} \ = \frac{m(m-1)\cdots(m-n+1)}{n!}= \frac{m^n}{n!}\cdot \left(1-\frac{1}{m}\right)\left(1-\frac{2}{m}\right)\cdots \left(1-\frac{n-1}{m}\right)$$
So, if we let \$c \$ be the product \$ \left(1-\frac{1}{m}\right)\left(1-\frac{2}{m}\right)\cdots \left(1-\frac{n-1}{m}\right)\$, we have
$$n! = \frac{m^n}{\binom{m}{n}} \cdot c$$
If we could just ignore \$c\$, we'd be done. The rest of this post is looking how large we need to make \$m\$ to be able to do this.
Note that \$c\$ approaches \$1\$ from below as \$ m \to \infty \$. We just need to make \$m\$ huge enough that omitting \$c\$ gives us a value with integer part \$n!\$ so that we may compute
$$n! = \left\lfloor \frac{m^n}{\binom{m}{n}} \right\rfloor $$
For this, it suffices to have \$1 - c < 1/n!\$ to avoid the ratio passing the next integer \$n!+1\$.
Observe that \$c\$ is a product of \$n\$ terms of which the smallest is \$ \left(1-\frac{n-1}{m}\right)\$. So, we have
$$c > \left(1-\frac{n-1}{m}\right)^n > 1 - \frac{n-1}{m} n > 1-\frac{n^2}{m},$$
which means \$1 - c < \frac{n^2}{m}\$. Since we're looking to have \$1 - c < 1/n!\$, it suffices to take \$m \geq n! \cdot n^2\$.
In the code, we use \$m=n^n\$. Since Wilson's Theorem uses \$(n-1)!\$, we actually only need \$m \geq (n-1)! \cdot (n-1)^2\$. It's easy to see that \$m=n^n\$ satisfies the bound for the small values and quickly outgrows the right hand side asymptotically, say with Stirling's approximation.

This answer doesn't use any number-theoretic cleverness. It spams Python's bitwise operators to create a manual "for loop", checking all pairs \$1 \leq i,j < n\$ to see whether \$i \times j = n\$.
Python 2, way too many bytes (278 thanks to Jo King in the comments!)
((((((2**(n*n)/(2**n-1)**2)*(2**((n**2)*n)/(2**(n**2)-1)**2))^((n*((2**(n*n-n)/(2**n-1))*(2**((n**2)*(n-1))/(2**n**2-1))))))-((2**(n*n-n)/(2**n-1))*(2**((n**2)*(n-1))/(2**(n**2)-1))))&(((2**(n*(n-1))/(2**n-1))*(2**((n**2)*(n-1))/(2**(n**2)-1)))*(2**(n-1)))==0))|((1<n<6)&(n!=4))

Try it online!
This is a lot more bytes than the other answers, so I'm leaving it ungolfed for now. The code snippet below contains functions and variable assignment for clarity, but substitution turns isPrime(n) into a single Python expression.
def count(k, spacing):
    return 2**(spacing*(k+1))/(2**spacing - 1)**2
def ones(k, spacing):
    return 2**(spacing*k)/(2**spacing - 1)

def isPrime(n):
    x = count(n-1, n)
    y = count(n-1, n**2)
    onebits = ones(n-1, n) * ones(n-1, n**2)
    comparison = n*onebits
    difference = (x*y) ^ (comparison)
    differenceMinusOne = difference - onebits
    checkbits = onebits*(2**(n-1))
    return (differenceMinusOne & checkbits == 0 and n>1)or 1<n<6 and n!=4

Why does it work?
I'll do the same algorithm here in base 10 instead of binary. Look at this neat fraction:
$$ \frac{1.0}{999^2} = 1.002003004005\dots $$
If we put a large power of 10 in the numerator and use Python's floor division, this gives an enumeration of numbers. For example, \$ 10^{15}/(999^2) = 1002003004 \$ with floor division, enumerating the numbers \$ 1,2,3,4 \$.
Let's say we multiply two numbers like this, with different spacings of zeroes. I'll place commas suggestively in the product.
$$ 1002003004 \times 1000000000002000000000003000000000004 = $$ $$ 1002003004,002004006008,003006009012,004008012016 $$
The product enumerates, in three-digit sequences, the multiplication table up to 4 times 4. If we want to check whether the number 5 is prime, we just have to check whether \$ 005 \$ appears anywhere in that product.
To do that, we XOR the above product by the number \$ 005005005\dots005 \$, and then subtract the number \$ 001001001\dots001 \$. Call the result \$d\$. If \$ 005 \$ appeared in the multiplication table enumeration, it will cause the subtraction to carry over and put \$ 999 \$ in the corresponding place in \$d\$.
To test for this overflow, we compute an AND of \$d\$ and the number \$ 900900900\dots900 \$. The result is zero if and only if 5 is prime.

A quick print of the expression puts this at 278 bytes (though I'm sure a lot of the parenthesises aren't necessary)

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


text:
number decomposition
It's been a while since I posted here, so here we go another day another challenge.
Challenge :
Given a number(n) split it into it's prime factors.

Input :
A positive non-zero integer greater than 2.

Output :
Decompose the number into it's prime factors and return the number of occurances of each prime in it.

Ouput format :
You can choose Any valid output format.

Example :
n = 86240
              v------------------------------- number of times it occurs in n
output : [[2, 5], [5, 1], [7, 2], [11, 1]]
           ^-------------------------------- prime number

n = 7775460
                           v--------------- 5 only occurs once in 7775460 so we don't need to write any power
output : [[2, 2], [3, 3], [5], [7], [11, 2], [17]]
            ^--------------------------------- same as first example

Note :

Prime factors have to be in either ascending order or descending order.
You may choose to either write 1 as power or note

Winning criterion :
This is code-golf so shortest code in bytes for each programming language wins

Jelly, 2 bytes
Built in command =)
ÆF

Try it online!

Brachylog, 10 bytes
ḋ≡ᵍ⟨h≡l⟩ᵐ

-1 bytes thanks to Erik the Outgolfer
Try it online!


text:
When in Rome, Count as Romans do?
Background
This challenge is inspired by this website, which published the following diagram:

This diagram shows us that the longest Roman Numeral expression under 250 is that of 188, which requires 9 numerals to express.
Challenge
The standard symbols used to express most Roman Numerals are the following: {I, V, X, L, C, D, M}, where the characters' numeric values are M=1000, D=500, C=100, L=50, X=10, V=5, I=1.
In this challenge, your goal is to, given an positive integer n, compute the number of valid Roman Numeral representations that can be composed through concatenating n of the standard symbols.
Then, your program must output the result of this computation!
Input: A positive integer n.
Output: The number of valid roman numeral expressions of length n.
Rules for Roman Numeral Expressions
Roman Numerals originally only had "additive" pairing, meaning that numerals were always written in descending order, and the sum of the values of all the numerals was the value of the number.
Later on, subtractive pairing, the use of placing a smaller numeral in front of a larger in order to subtract the smaller from the larger, became commonplace to shorten Roman Numeral expressions. Subtractive pairs cannot be chained, like in the following invalid expression: IXL.
The following are the modern day rules for additive and subtractive pairing.

Only one I, X, and C can be used as the leading numeral in part of a subtractive pair.
I can only be placed before V or X in a subtractive pair.
X can only be placed before L or C in a subtractive pair.
C can only be placed before D or M in a subtractive pair.
Other than subtractive pairs, numerals must be in descending order (meaning that if you drop the leading numeral of each subtractive pair, then the numerals will be in descending order).
M, C, and X cannot be equalled or exceeded by smaller denominations.
D, L, and V can each only appear once.
Only M can be repeated 4 or more times.

Further Notes

We will not be using the bar notation; rather, we will simply add more Ms to express any number.
These are the only rules that we will follow for our roman numerals. That means that odd expressions, such as IVI, will also be considered valid in our system.
Also remember that we are not counting the number of numbers that have expressions of length n, since some numbers have multiple expressions. Instead, we are solely counting the number of valid expressions.

Test Cases
1 → 7
2 → 31
3 → 105
I checked the above by hand, so please make sure to double check the test cases, and add more if you can!
Winning Criteria
This is a code-golf challenge, so have fun! I will only accept solutions that can handle at least inputs from 1 through 9. Any more is bonus!
Edit
As requested by commenters, find below, or at this pastebin link, the 105 combos I counted for n=3

III
  IVI
  IXI
  IXV
  IXX
  VII
  XII
  XIV
  XIX
  XVI
  XXI
  XXV
  XXX
  XLI
  XLV
  XLX
  XCI
  XCV
  XCX
  XCL
  XCC
  LII
  LIV
  LIX
  LVI
  LXI
  LXV
  LXX
  CII
  CIV
  CIX
  CVI
  CXI
  CXV
  CXX
  CXL
  CXC
  CLI
  CLV
  CLX
  CCI
  CCV
  CCX
  CCL
  CCC
  CDI
  CDV
  CDX
  CDL
  CDC
  CMI
  CMV
  CMX
  CML
  CMC
  CMD
  CMM
  DII
  DIV
  DIX
  DVI
  DXI
  DXV
  DXX
  DXL
  DXC
  DLI
  DLV
  DLX
  DCI
  DCV
  DCX
  DCL
  DCC
  MII
  MIV
  MIX
  MVI
  MXI
  MXV
  MXX
  MXL
  MXC
  MLI
  MLV
  MLX
  MCI
  MCV
  MCX
  MCL
  MCC
  MCD
  MCM
  MDI
  MDV
  MDX
  MDL
  MDC
  MMI
  MMV
  MMX
  MML
  MMC
  MMD
  MMM

Edit 2:
Use the following non-golfed code, as courtesy of Jonathan Allan to check your results.
Edit 3:
I apologize for all of the errors in this challenge. I'll make sure to do a better job next time!

Comments are not for extended discussion; this conversation has been moved to chat.

Retina, 111 bytes
~(`.+
*$(CM)CDXCXCXCXLIXIXIXIVII
.(.)
.+¶$$&$¶$$&$1$¶$$&$&¶L`.{0,$+}\b¶D`¶
¶$
¶.+¶$$&$¶$$&I¶L`[A-Z]{$+}\b¶D`¶.+

Try it online! This is a complete rewrite as I misunderstood rule 1. to mean that you could only use one each of subtractive I, X and C. Explanation: The first part of the script expands the input into a string of CM pairs followed by the other possible subtractive pairs. Each pair is optional, and the first character of each pair is also optional within the pair. The third stage then expands the list of pairs into a list of Retina commands that take the input and create three copies with the option of the second or both characters from the pair, then trims and deduplicates the results. The final stage then appends code to perform the final tasks: first to expand the input to possibly add a final I, then to filter out results of the wrong length, then to deduplicate the results, and finally to count the results. The resulting Retina script is then evaluated.
Note: In theory 15 bytes could be saved from the end of the 4th line but this makes the script too slow to demonstrate on TIO even for n=1.

@JonathanAllan Ah, then you're including multiple subtractive pairs with the same leading numeral, which is wrong.

@JonathanAllan New rewrite, coincidentally for the exact same byte count!

Python 2, 177 168 162 bytes
import re,itertools as q
f=lambda n:sum(None!=re.match("^M*(CM|CD|D?C{0,3})(XC|XL|L?X{0,3})(IX|IV|V?I{0,3})$",(''.join(m)))for m in q.product('MDCLXVI',repeat=n))

Try it online!
I'm pretty new, help me golf this! This checks for actual roman numerals, the regex needs to be adjusted to account for the odd cases such as IVI
-9 bytes thanks to @Dead Possum!
-6 bytes thanks to @ovs

Yeah I think the n=3 case might be wrong in the example. I was originally getting 93 with ^M*(CM|CD|D?C{0,3})(XC|XL|L?X{0,3})(IX|IV|V?I{0,3})$

171 bytes

FWIW your numbers aggree with http://oeis.org/A199921 ...it has a(4)=215, but MMMM would make that 216 :)

@JonathanAllan Good to know :) Thanks!

Now we have a list of the n=3 values considered correct by the OP I believe the shortfall is the lack of some of the noted "odd expressions" like "IVI".

@JonathanAllan I would be willing to adjust the rules if that made the answer easier/more consistent.

@RushabhMehta - that is totally up to you, your definitions are, I believe, workable (and interesting to code for) even if they do produce what we now consider "invalid" Roman numerals, back then they may have been used? (I'm no expert)

@JonathanAllan I spent around two days asking around on Math stackexchange trying to make sure these rules made sense. Guess I didn't do enough :(

@RushabhMehta This is a very well formatted challenge and fun to program, don't feel bad about an unfortunate nuance in nitty-gritty of roman numeral definition. It is your challenge, specify it as you see fit. it is workable in the other sense, just more difficult

This doesn't seem to give the right answer for 3. 93 instead of 105

JavaScript (ES7), 133 bytes
Edit: Fixed to match the results returned by Jonathan Allan's code, which was given as a reference implementation by the OP.

n=>[...Array(m=k=7**n)].reduce(s=>s+/^1*5?4{0,3}3?2{0,3}6?0{0,3}$/.test((--k+m).toString(7).replace(/0[62]|2[34]|4[51]/g,s=>s[1])),0)

Try it online!
How?
1) We generate all numbers of \$N\$ digits in base 7 with an extra leading \$1\$:
[...Array(m = k = 7 ** n)].reduce(s => … (--k + m).toString(7) …, 0)

From now on, each digit will be interpreted as a Roman numeral symbol:
$$\begin{array}{}0\longleftrightarrow \text{I}, & 1\longleftrightarrow \text{M}, & 2\longleftrightarrow \text{X}, & 3\longleftrightarrow \text{L},\\
4\longleftrightarrow \text{C}, & 5\longleftrightarrow \text{D}, & 6\longleftrightarrow \text{V}
\end{array}$$
2) We replace all valid subtractive pairs of the form AB with B:
.replace(/0[62]|2[34]|4[51]/g, s => s[1]))  // in the code
.replace(/I[VX]|X[LC]|C[DM]/g, s => s[1]))  // with Roman symbols

Examples:

XLIXIV becomes LXV
XIIV becomes XIV, leaving a I that will make the next test fail
IC remains unchanged, which also leaves an invalid I in place

3) We check that the remaining symbols are in the correct order and do not appear more times than they're allowed to:
/^1*5?4{0,3}3?2{0,3}6?0{0,3}$/.test(…)  // in the code
/^M*D?C{0,3}L?X{0,3}V?I{0,3}$/.test(…)  // with Roman symbols

Holy cow, I didn't expect this one to be done in less than 200 bytes in non esoteric languages! Mind explaining how this works?

However, I have noticed that this doesn't work for n>4 on TIO, which is somewhat unfortunate.

@RushabhMehta I've added a non-recursive version to test higher values. I'll add an explanation when I'm done golfing this.

C, 150 123 bytes
I didn't read the description closely enough, so this produces the number of standard Roman numerals (where expressions like IVI aren't counted). Since I put some effort into it, I thought I would share anyway.
#define F(X) for(X=10;X--;)
x[]={0,1,2,3,2,1,2,3,4,2};f(i,o,a,b,c){for(i++;i--;)F(a)F(b)F(c)o+=i==x[a]+x[b]+x[c];return o;}

Original (150 bytes):
#define F(X) for(X=10;X--;)
i,o,a,b,c,x[]={0,1,2,3,2,1,2,3,4,2};main(){scanf("%i",&i);for(i++;i--;)F(a)F(b)F(c)o+=i==x[a]+x[b]+x[c];printf("%i\n",o);}

You're only allowed to post valid submissions.

@CurtisBechtel You can keep the solution here I suppose, but I would try to modify it to satisfy the rules of the challenge.

I think you can remove the space between F(X) and for(X=10;X--;)


text:
Goldbach's Comet
Back to back challenges I guess. Hopefully this one is more clear than the last.
Background
I was playing around with Goldbach's conjecture, and decided to plot evens (on the x-axis) vs the number of ways that two primes could be found to sum to a given even on the y axis.
The two plots I've made below in Python are for 10,000 and 1,000,000 evens.

The structure of these graphs is really fascinating! So I decided to go further and color different types of evens (those divisible by different numbers) different colors.
What I found was that each band represented a set of evens divisible by some odd number, e.g., 3, 5, 7, 9. So that got me thinking of the following challenge. I would post the picture, but doing so might make this challenge a bit too easy, so I'll refrain till after I've crowned someone a victor.
Challenge
Define G(x) to be a function defined on the positive evens which returns the number of different ways to sum two primes numbers to form x. Note that the primes are indistinguishable, i.e., 3+5 and 5+3 are considered equivalent.
This is a code-challenge challenge where your goal is the following:
Find 3 differentiable and concave functions f,g,h defined on the positive reals such that:

For any even divisible by 6 and less than 10,000,000, and any real y less than or equal to this even, f(y)<=G(even)
For any even divisible by 10 and less than or equal to 10,000,000, and any real y less than or equal to this even, g(y)<=G(even)
For any even divisible by 14 and less than 10,000,000, and any real y less than or equal to this even, h(y)<=G(even)

Your score will be the integral from 0 to 10,000,000 of (f+g+h).
Rules

Each submission must not only include the formulas for all three of these functions, but show through code in whatever language they see fit that the conditions of the challenge are met.
Each submission must also calculate the integral of their score. This can be done in a separate language if so desired by the user (or by hand if you are a masochist).
Once a submission has been made, any submission whose score is not at least 5 points higher than the previous submission will not dethrone the current winning submission.

Prizes
I don't have much reputation, but I'll put up a +50 bounty for first place, along with a +15 for accept. This is somewhat of a new type of challenge for this site, so enjoy!
Edit
Considering the poor reception this problem has received, I will no longer be offering a prize for this problem. However, I'm working on designing another one, which hopefully will have a prize associated with it!

It looks like you have also posted this challenge in the sandbox. I recommend deleting this one until you become confident that you can post it.

for G(x) does 3+5 and 5+3 mean different way or are they the same?

@Kroppeb Sorry, those are not different. I will add that to the question.

This challenge is flawed because the score can be arbitrarily high and irrelevant to the problem. Functions $f, g, h$ are always zero for integer $x$:
$$f(x) = g(x) = h(x) = c(1 - \cos(2\pi x))$$
But can have arbitrarily high integral.

Probably OP intended "monotonic" or "linear" or something.

@orlp You didn't read correctly. Note that for any even and any real y less than that even, f(y)<G(even)

@orlp So your function would NOT be allowed.

@user202729 I don't need to specify monotonicity because of the properties of the function that I have specified.

Ok, I see. But... it's still flawed. Submissions' score can be arbitrarily close to the optimal score (you specified that the functions must be continuous, but the optimal function satisfy all other conditions except continuity is a staircase-like function -- and functions that are noncontinuous at finitely many points can be arbitrary-closely approximated by continuous function)

@user202729 See the new edits

May I ask why you have a paragraph dedicated to prizes which is immediately followed by a paragraph which details why the above paragraph is of no significance?

@JonathanFrech I was planning on offering a bounty on this question, but due to the poor reception of the question, I decided to just let this question die, hence the edit

@RushabhMehta I am just saying that it seems a bit deceptive to offer a prize in one paragraph and withdraw it in the next. I would have simply removed the offer.

On another note, I do not feel like "let[ting] this question die" is appropriate. Please either delete this question or edit it so that it is not left to die.


text:
RTA (Reverse-Then-Add) root of a number
The reverse-then-add (RTA) sequence is a sequence obtained by adding a number to its reverse, and repeating the process on the result. For eg.,
$$ 5 + 5 = 10 \Rightarrow 10 + 01 = 11 \Rightarrow 11 + 11 = 22 \Rightarrow 22 + 22 = 44 \Rightarrow\text{ }...  $$
Thus, 5's RTA sequence contains 10, 11, 22, 44, 88, 176, etc.
The RTA root of a number \$n\$ is the smallest number that is either equal to \$n\$ or gives raise to \$n\$ in its RTA sequence.
For eg., 44 is found in the RTA sequence of 5, 10, 11, 13, 22, 31, etc. Of these, 5 is the smallest, and hence RTAroot(44) = 5.
72 is not part of any number's RTA sequence, and so is considered its own RTA root.
Input is a positive integer in a range that your language can naturally handle.
Output is the RTA root of the given number, as defined above.
Test cases
Input
Output

44
5

72
72

132
3

143
49

1111
1

999
999

Related OEIS: A067031. The output will be a number from this sequence.

Perl 6 Raku, 45 44 39 bytes
{+(1...{$_∈($^a,{$_+.flip}...*>$_)})}

Try it online!
Explanation:
{                                   }  # Anonymous code block
 +(1...                            )     # Find the first integer
       {                          }      # Where
        $_∈                              # The input is an element of
           (              ...    )         # A sequence defined by
            $^b,                           # The first element is the number we're checking
                {$_+.flip}                 # Each element is the previous element plus its reverse
                             *>$_          # The last element is larger than the input

The Perl 6 ellipsis syntax gets more magical every time I come across it. That lambda-based sequence specification is such a neat idea!

@sundar, that syntax was actually one of the main reasons why I came over to Perl 6. (and why, after some time, it became my most favorite language)

Brachylog, 24 22 bytes
{~{ℕ≤.&≜↔;?+}{|↰₁}|}ᶠ⌋

2 bytes thanks to sundar noticing that I had a {{ and }}

Explanation
                --  f(n):
                --      g(x):
 {              --          h(y):
  ~             --              get z where k(z) = y
   {            --              k(z):
    ℕ≤.         --                  z>=0 and z<=k(z) (constrain so it doesn't keep looking)
    &≜          --                  label input (avoiding infinite stuff)
      ↔;?+      --                  return z+reverse(z)
   }            --
    {           --
     |↰₁        --              return z and h(z) (as in returning either)
    }           --
  |             --          return h(x) or x (as in returning either)
 }              --
ᶠ               --      get all possible answers for g(n)
  ⌋             --      return smallest of them

sorry for the wonky explanation, this is the best i could come up with
Try it online!

The use of {|↰₁} there is simple but brilliant. Good work!

Haskell, 59 57 bytes
-2 bytes thanks to user1472751 (using a second until instead of list-comprehension & head)!
f n=until((n==).until(>=n)((+)<*>read.reverse.show))(+1)1

Try it online!
Explanation
This will evaluate to True for any RTA-root:
(n==) . until (n<=) ((+)<*>read.reverse.show)

The term (+)<*>read.reverse.show is a golfed version of
\r-> r + read (reverse $ show r)

which adds a number to itself reversed.
The function until repeatedly applies (+)<*>read.reverse.show until it exceeds our target.
Wrapping all of this in yet another until starting off with 1 and adding 1 with (+1) will find the first RTA-root.
If there is no proper RTA-root of n, we eventually get to n where until doesn't apply the function since n<=n.

You can save 2 bytes by using until for the outer loop as well: TIO

05AB1E, 7 bytes
Using the new version of 05AB1E (rewritten in Elixir).
Code
L.ΔλjÂ+

Try it online!
Explanation
L           # Create the list [1, ..., input]
 .Δ         # Iterate over each value and return the first value that returns a truthy value for:
   λ        #   Where the base case is the current value, compute the following sequence:
     Â+     #   Pop a(n - 1) and bifurcate (duplicate and reverse duplicate) and sum them up.
            #   This gives us: a(0) = value, a(n) = a(n - 1) + reversed(a(n - 1))
    j       #   A λ-generator with the 'j' flag, which pops a value (in this case the input)
            #   and check whether the value exists in the sequence. Since these sequences will be
            #   infinitely long, this will only work strictly non-decreasing lists.

Wait.. j has a special meaning in a recursive environment? I only knew about the ₁ through ₆ and the λ itself within the recursive environment. Are there any more besides j? EDIT: Ah, I see something about £ as well in the source code. Where is it used for?

@KevinCruijssen Yes, these are flags used in the recursive environment. j essentially checks whether the input value is in the sequence. £ makes sure it returns the first n values of the sequence (same as λ<...>}¹£).

Jelly, 12 11 bytes
ṚḌ+ƊÐ¡€œi¹Ḣ

This is a full program. Run time is roughly quadratic; test cases \$999\$ and \$1111\$ time out on TIO.
Thanks to @JonathanAllan for golfing off 1 byte!
Try it online!
How it works
ṚḌ+ƊÐ¡€œi¹Ḣ  Main link. Argument: n

      €      Map the link to the left over [1, ..., n].
    Ð¡         For each k, call the link to the left n times. Return the array of k
               and the link's n return values.
   Ɗ           Combine the three links to the left into a monadic link. Argument: j
Ṛ                Promote j to its digit array and reverse it.
 Ḍ               Undecimal; convert the resulting digit array to integer.
  +              Add the result to j.
       œi¹   Find the first multindimensional index of n.
          Ḣ  Head; extract the first coordinate.

Ruby, 66 57 bytes
f=->n{(1..n).map{|m|m+(m.digits*'').to_i==n ?f[m]:n}.min}

Try it online!
Recursive function that repeatedly "undoes" the RTA operation until arriving at a number that can't be produced by it, then returns the minimum.
Instead of using filter, which is long, I instead simply map over the range from 1 to the number. For each m in this range, if m + rev(m) is the number, it calls the function recursively on m; otherwise, it returns n. This both removes the need for a filter and gives us a base case of f(n) = n for free.
Highlights include saving a byte with Integer#digits:
m.to_s.reverse.to_i
(m.digits*'').to_i
eval(m.digits*'')

The last one would be a byte shorter, but sadly, Ruby parses numbers starting with 0 as octal.

JavaScript (ES6), 61 bytes
n=>(g=k=>k-n?g(k>n?++x:+[...k+''].reverse().join``+k):x)(x=1)

Try it online!
Commented
n =>                        // n = input
  (g = k =>                 // g() = recursive function taking k = current value
    k - n ?                 //   if k is not equal to n:
      g(                    //     do a recursive call:
        k > n ?             //       if k is greater than n:
          ++x               //         increment the RTA root x and restart from there
        :                   //       else (k is less than n):
          +[...k + '']      //         split k into a list of digit characters
          .reverse().join`` //         reverse, join and coerce it back to an integer
          + k               //         add k
      )                     //     end of recursive call
    :                       //   else (k = n):
      x                     //     success: return the RTA root
  )(x = 1)                  // initial call to g() with k = x = 1

Pyth, 12 bytes
fqQ.W<HQ+s_`

Check out a test suite!
Surprisingly fast and efficient. All the test cases ran at once take less than 2 seconds.
How it works
fqQ.W<HQ+s_` – Full program. Q is the variable that represents the input.
f            – Find the first positive integer T that satisfies a function.
   .W        – Functional while. This is an operator that takes two functions A(H)
               and B(Z) and while A(H) is truthy, H = B(Z). Initial value T.
     <HQ     – First function, A(H) – Condition: H is strictly less than Q.
        +s_` – Second function, B(Z) – Modifier.
         s_` – Reverse the string representation of Z and treat it as an integer.
        +    – Add it to Z.
             – It should be noted that .W, functional while, returns the ending
               value only. In other words ".W<HQ+s_`" can be interpreted as
               "Starting with T, while the current value is less than Q, add it
               to its reverse, and yield the final value after the loop ends".
 qQ          – Check if the result equals Q.

Python 2, 70 bytes
f=lambda n,i=1,k=1:i*(k==n)or f(n,i+(k>n),[k+int(`k`[::-1]),i+1][k>n])

Try it online!

05AB1E, 21 16 15 bytes
G¼N¹FÂ+Ð¹Qi¾q]¹

-1 byte thanks to @Emigna.
Try it online.
Explanation:
G               # Loop `N` in the range [1, input):
 ¼              #  Increase the global_counter by 1 first every iteration (0 by default)
 N              #  Push `N` to the stack as starting value for the inner-loop
  ¹F            #  Inner loop an input amount of times
    Â           #   Bifurcate (short for Duplicate & Reverse) the current value
                #    i.e. 10 → 10 and '01'
     +          #   Add them together
                #    i.e. 10 and '01' → 11
      Ð         #   Triplicate that value
                #   (one for the check below; one for the next iteration)
       ¹Qi      #   If it's equal to the input:
          ¾     #    Push the global_counter
           q    #    And terminate the program
                #    (after which the global_counter is implicitly printed to STDOUT)
]               # After all loops, if nothing was output yet:
 ¹              # Output the input

You don't need the print due to implicit printing.

05AB1E, 13 bytes
LʒIFDÂ+})Iå}н

Try it online!
Explanation
L               # push range [1 ... input]
 ʒ         }    # filter, keep elements that are true under:
  IF   }        # input times do:
    D           # duplicate
     Â+         # add current number and its reverse
        )       # wrap in a list
         Iå     # check if input is in the list
            н   # get the first (smallest) one

Smart! I know my 21 bytes version was already way too long (which I've golfed to 16 with the same approach), but couldn't really figure out a way to do it shorter. Can't believe I haven't thought about using head after the filter.. I kept trying to use the loop index+1, or the global_counter.. >.>

Charcoal, 33 bytes
Ｎθ≔⊗θηＷ›ηθ«≔Ｌ⊞ＯυωηＷ‹ηθ≧⁺Ｉ⮌Ｉηη»ＩＬυ

Try it online! Link is to verbose version of code. Explanation:
Ｎθ

Input \$q\$.
≔⊗θη

Assign \$2q\$ to \$h\$ so that the loop starts.
Ｗ›ηθ«

Repeat while \$h>q\$:
≔Ｌ⊞Ｏυωη

push a dummy null string to \$u\$ thus increasing its length, and assign the resulting length to \$h\$;
Ｗ‹ηθ

repeat while \$h<q\$:
≧⁺Ｉ⮌Ｉηη

add the reverse of \$h\$ to \$h\$.
»ＩＬυ

Print the final length of \$u\$ which is the desired root.

MATL, 17 bytes
`@G:"ttVPU+]vG-}@

Try it online!
Explanation
`         % Do...while loop
  @       %   Push iteration index, k (starting at 1)
  G:"     %   Do as many times as the input
    tt    %     Duplicate twice
    VPU   %     To string, reverse, to number
    +     %     Add
  ]       %   End
  v       %   Concatenate all stack into a column vector. This vector contains
          %   a sufficient number of terms of k's RTA sequence
  G-      %   Subtract input. This is used as loop condition, which is falsy
          %   if some entry is zero, indicating that we have found the input
          %   in k's RTA sequence
}         % Finally (execute on loop exit)
  @       %   Push current k
          % End (implicit). Display (implicit)

Just as a side note, I used MATL to generate the test case outputs, using this 31 byte version: :!`tG=~yV2&PU*+tG>~*tXzG=A~]f1) Try it online!

C (gcc), 120 100 99 bytes
f(i,o,a,b,c,d){for(a=o=i;b=a;o=i/b?a:o,a--)for(;b<i;b+=c)for(c=0,d=b;d;d/=10)c=c*10+d%10;return o;}

Try it online!
Given input i, checks every integer from i to 0 for a sequence containing i.

i is the input value
o is the output value (the minimum root found so far)
a is the current integer being checked
b is the current element of a's sequence
c and d are used to add b to its reverse

Compiling with -DL=for would save you 2 bytes.

Scratch that; doing math wrong.

However, you can return the output value with i=o; if you use -O0, saving you 5 bytes.

Java 8, 103 bytes
n->{for(int i=0,j;;)for(j=++i;j<=n;j+=n.valueOf(new StringBuffer(j+"").reverse()+""))if(n==j)return i;}

Try it online.
Explanation:
n->{                // Method with Integer as both parameter and return-type
  for(int i=0,j;;)  //  Infinite loop `i`, starting at 0
    for(j=++i;      //  Increase `i` by 1 first, and then set `j` to this new `i`
        j<=n        //  Inner loop as long as `j` is smaller than or equal to the input
        ;           //    After every iteration:
         j+=        //     Increase `j` by:
            n.valueOf(new StringBuffer(j+"").reverse()+""))
                    //     `j` reversed
     if(n==j)       //   If the input and `j` are equal:
       return i;}   //    Return `i` as result

Arithmetically reversing the integer is 1 byte longer (104 bytes):
n->{for(int i=0,j,t,r;;)for(j=++i;j<=n;){for(t=j,r=0;t>0;t/=10)r=r*10+t%10;if((j+=r)==n|i==n)return i;}}

Try it online.

Japt, 16 15 11 bytes
@ÇX±swÃøU}a

Try it
@ÇX±swÃøU}a     :Implicit input of integer U
@        }a     :Loop over the positive integers as X & output the first that returns true
 Ç              :  Map the range [0,U)
  X±            :    Increment X by
    sw          :    Its reverse
      Ã         :  End map
       øU       :  Contains U?

Physica, 57 bytes
Credit for the method goes to Doorknob.
F=>N:Min@Map[->m:N==m+Int[Str[m]{%%-1}]&&F@m||N;…[1;N]]

Try it online!

C (gcc), 89 bytes
I run each sequence in [1,n) until I get a match; zero is special-cased because it doesn't terminate.
j,k,l,m;r(i){for(j=k=0;k-i&&++j<i;)for(k=j;k<i;k+=m)for(l=k,m=0;l;l/=10)m=m*10+l%10;j=j;}

Try it online!

Husk, 9 bytes
ḟo£⁰¡S+↔N

Try it online!
first element in natural numbers which has an infinite list that contains the input.


text:
A knight's graph on an N-by-N board
In chess, a knight can only move to the positions marked with X relative to its current position, marked with ♞:

A Knight's Graph is a graph that represents all legal moves of the knight chess piece on a chessboard. Each vertex of this graph represents a square of the chessboard, and each edge connects two squares that are a knight's move apart from each other.
The graph looks like this for a standard 8-by-8 board.

Challenge:
Given an integer N, where 3 ≤ N ≤ 8, output an N-by-N matrix representing a board, where the number of possible moves from each position is shown. For N = 8, the output will be a matrix showing the values of each vertex in the graph above.
The output format is flexible. List of lists or even a flattened list etc. are accepted formats.

Complete set of test cases:
--- N = 3 ---
2 2 2
2 0 2
2 2 2
--- N = 4 ---
2 3 3 2
3 4 4 3
3 4 4 3
2 3 3 2
--- N = 5 ---
2 3 4 3 2
3 4 6 4 3
4 6 8 6 4
3 4 6 4 3
2 3 4 3 2
--- N = 6 ---
2 3 4 4 3 2
3 4 6 6 4 3
4 6 8 8 6 4
4 6 8 8 6 4
3 4 6 6 4 3
2 3 4 4 3 2
--- N = 7 ---
2 3 4 4 4 3 2
3 4 6 6 6 4 3
4 6 8 8 8 6 4
4 6 8 8 8 6 4
4 6 8 8 8 6 4
3 4 6 6 6 4 3
2 3 4 4 4 3 2
--- N = 8 ---
2 3 4 4 4 4 3 2
3 4 6 6 6 6 4 3
4 6 8 8 8 8 6 4
4 6 8 8 8 8 6 4
4 6 8 8 8 8 6 4
4 6 8 8 8 8 6 4
3 4 6 6 6 6 4 3
2 3 4 4 4 4 3 2

This is code-golf so the shortest solution in each language wins. Explanations are encouraged!

Related challenge to query the number of knight moves from a square on an 8*8 board.

Can the output be a flat list of n*n elements?

This is literally just edge-cases! :)

MATL, 17 16 bytes
t&l[2K0]B2:&ZvZ+

Try it online!
(-1 byte thanks to @Luis Mendo.)
The main part of the code is creating a matrix \$ K \$ for convolution:
$$ \mathbf{K} = \begin{pmatrix}0&1&0&1&0\\1&0&0&0&1\\0&0&0&0&0\\1&0&0&0&1\\0&1&0&1&0\end{pmatrix} $$
(Relative to the centre of the matrix, each 1 is a valid knight's move.)
t&l - Form a nxn matrix of all 1s (where n is the input). Let this be M.
[2K0] - Push an array containing [2, 4, 0] on stack
B  - Convert all to binary, padding with 0s as needed
0 1 0
1 0 0
0 0 0

2:&Zv - Mirror that on both dimensions, without repeating the final row/column ("symmetric range indexing").
This gives us the required matrix K.
0 1 0 1 0
1 0 0 0 1
0 0 0 0 0
1 0 0 0 1
0 1 0 1 0

Z+ - Perform 2D convolution of K over the earlier matrix M (conv2(M, K, 'same')),
summing up the 1s at legal knight move targets for each position
Result matrix is displayed implicitly.

you can encode the convolution matrix as 11043370BP5e but that's not any shorter...

Python 2, 81 bytes
lambda n:[sum(2==abs((i/n-k/n)*(i%n-k%n))for k in range(n*n))for i in range(n*n)]

Try it online!

JavaScript (ES6), 88 bytes
Returns a string.
n=>(g=k=>--k?[n>3?'-2344-6-6'[(h=k=>k*2<n?~k:k-n)(k%n)*h(k/n|0)]||8:k-4&&2]+g(k):2)(n*n)

Try it online!
How?
Special case: \$n=3\$
We fill each cell with \$2\$, except the center one which is set to \$0\$:
$$\pmatrix{2 & 2 & 2\\
2 & 0 & 2\\
2 & 2 & 2}$$
Other cases: \$3<n\le 8\$
For each cell \$(x,y)\$ with \$0\le x<n\$ and \$0\le y<n\$, we compute a lookup index \$i_{x,y}\$ defined as:
$$i_{x,y}=\min(x+1,n-x)\times \min(y+1,n-y)$$
For \$n=8\$, this gives:
$$\pmatrix{1 & 2 & 3 & 4 & 4 & 3 & 2 & 1\\
2 & 4 & 6 & 8 & 8 & 6 & 4 & 2\\
3 & 6 & 9 & 12 & 12 & 9 & 6 & 3\\
4 & 8 & 12 & 16 & 16 & 12 & 8 & 4\\
4 & 8 & 12 & 16 & 16 & 12 & 8 & 4\\
3 & 6 & 9 & 12 & 12 & 9 & 6 & 3\\
2 & 4 & 6 & 8 & 8 & 6 & 4 & 2\\
1 & 2 & 3 & 4 & 4 & 3 & 2 & 1}$$
The lookup table \$T\$ is defined as:
$$T = [0,2,3,4,4,0,6,0,6]$$
where \$0\$ represents an unused slot.
We set each cell \$(x,y)\$ to:
$$\begin{cases}T(i_{x,y})&\text{if }i_{x,y} \le 8\\8&\text{otherwise}\end{cases}$$

JavaScript (ES7), 107 bytes
A naive implementation which actually tries all moves.
n=>[...10**n-1+''].map((_,y,a)=>a.map((k,x)=>~[...b=i='01344310'].map(v=>k-=!a[x-v+2]|!a[y-b[i++&7]+2])+k))

Try it online!

Jelly,  23 22 14  10 bytes
²ḶdðạP€ċ2)

A monadic link yielding a flat list - uses the idea first used by KSab in their Python answer - knight's moves have "sides" 1 and 2, the only factors of 2.
Try it online! (footer calls the program's only Link and then formats the result as a grid)
Alternatively, also for 10 bytes, ²Ḷdðạ²§ċ5) (knight's moves are all of the possible moves with distance \$\sqrt{5}\$)
How?
²ḶdðạP€ċ2) - Link: integer, n (any non-negative) e.g. 8
²          - square n                                 64
 Ḷ         - lowered range                            [0,    1,    2,    3,    4,    5,    6,    7,    8,    9,    10,   11,   12,   13,   14,   15,   16,   17,   18,   19,   20,   21,   22,   23,   24,   25,   26,   27,   28,   29,   30,   31,   32,   33,   34,   35,   36,   37,   38,   39,   40,   41,   42,   43,   44,   45,   46,   47,   48,   49,   50,   51,   52,   53,   54,   55,   56,   57,   58,   59,   60,   61,   62,   63]
  d        - divmod (vectorises) i.e. x->[x//n,x%n]   [[0,0],[0,1],[0,2],[0,3],[0,4],[0,5],[0,6],[0,7],[1,0],[1,1],[1,2],[1,3],[1,4],[1,5],[1,6],[1,7],[2,0],[2,1],[2,2],[2,3],[2,4],[2,5],[2,6],[2,7],[3,0],[3,1],[3,2],[3,3],[3,4],[3,5],[3,6],[3,7],[4,0],[4,1],[4,2],[4,3],[4,4],[4,5],[4,6],[4,7],[5,0],[5,1],[5,2],[5,3],[5,4],[5,5],[5,6],[5,7],[6,0],[6,1],[6,2],[6,3],[6,4],[6,5],[6,6],[6,7],[7,0],[7,1],[7,2],[7,3],[7,4],[7,5],[7,6],[7,7]]
   ð     ) - new dyadic chain for each - call that L ( & e.g. R = [1,2] representing the "2nd row, 3rd column" ...-^ )
    ạ      -   absolute difference (vectorises)       [[1,2],[1,1],[1,0],[1,1],[1,2],[1,3],[1,4],[1,5],[0,2],[0,1],[0,0],[0,1],[0,2],[0,3],[0,4],[0,5],[1,2],[1,1],[1,0],[1,1],[1,2],[1,3],[1,4],[1,5],[2,2],[2,1],[2,0],[2,1],[2,2],[2,3],[2,4],[2,5],[3,2],[3,1],[3,0],[3,1],[3,2],[3,3],[3,4],[3,5],[4,2],[4,1],[4,0],[4,1],[4,2],[4,3],[4,4],[4,5],[5,2],[5,1],[5,0],[5,1],[5,2],[5,3],[5,4],[5,5],[6,2],[6,1],[6,0],[6,1],[6,2],[6,3],[6,4],[6,5]]
     P€    -   product of €ach                        [2,    1,    0,    1,    2,    3,    4,    5,    0,    0,    0,    0,    0,    0,    0,    0,    2,    1,    0,    1,    2,    3,    4,    5,    4,    2,    0,    2,    4,    6,    8,    10,   6,    3,    0,    3,    6,    9,    12,   15,   8,    4,    0,    4,    8,    12,   16,   20,   10,   5,    0,    5,    10,   15,   20,   25,   12,   6,    0,    6,    12,   18,   24,   30]
       ċ2  -   count 2s                          6:    ^-...1                  ^-...2                                                                  ^-...3                  ^-...4                        ^-...5      ^-...6
           - )                                                                                v-...that goes here
           -   ->                                  -> [2,    3,    4,    4,    4,    4,    3,    2,    3,    4,    6,    6,    6,    6,    4,    3,    4,    6,    8,    8,    8,    8,    6,    4,    4,    6,    8,    8,    8,    8,    6,    4,    4,    6,    8,    8,    8,    8,    6,    4,    4,    6,    8,    8,    8,    8,    6,    4,    3,    4,    6,    6,    6,    6,    4,    3,    2,    3,    4,    4,    4,    4,    3,    2]

Previous 22 byter
2RżN$Œp;U$+,ḟ€³R¤Ẉ¬Sðþ

A full program (due to ³).
Try it online! (footer calls the program's only Link and then formats the result as a grid)
Finds all moves and counts those which land on the board probably definitely beatable by calculating (maybe beatable by changing the "land on the board" logic).

APL (Dyalog Classic), 18 bytes
+/+/2=×/¨|∘.-⍨⍳2⍴⎕

Try it online!
⎕ evaluated input N
2⍴⎕ two copies of N
⍳2⍴⎕ the indices of an N×N matrix - a matrix of length-2 vectors
∘.-⍨ subtract each pair of indices from each other pair, get an N×N×N×N array
| absolute value
×/¨ product each
2= where are the 2s? return a boolean (0/1) matrix
Note that a knight moves ±1 on one axis and ±2 on the other, so the absolute value of the product of those steps is 2. As 2 can't be factored in any other way, this is valid only for knight moves.
+/+/ sum along the last dimension, twice

Brachylog, 65 40 33 bytes
This breaks down for N bigger then 9. So I'm happy N can be only go to 8 =)
⟦₅⟨∋≡∋⟩ᶠ;?z{{hQ&t⟦₅↰₁;Qz-ᵐ×ȧ2}ᶜ}ᵐ

-25 bytes by switching to KSab's formula
-7  bytes by flattening the array thanks to sundar

Try it online!

Brachylog, 44 36 bytes
This one also works for number higher then 9
gP&⟦₅⟨∋≡∋⟩ᶠ;z{{hQ&t⟦₅↰₁;Qz-ᵐ×ȧ2}ᶜ}ᵐ

-8  bytes by flattening the array thanks to sundar

Try it online!

You can use the ⟨∋≡∋⟩ early on to generate the matrix coordinates too, and save 7 bytes overall (output is a flat list, which is allowed by OP): Try it online!

RAD, 51 46 39 bytes
{+/(⍵∘+¨(⊖,⊢)(⊢,-)(⍳2)(1¯2))∊,W}¨¨W←⍳⍵⍵

Try it online!
How?
Counts the number of valid knight moves for each square by seeing which knight moves would land on the board:
{+/(⍵∘+¨(⊖,⊢)(⊢,-)(⍳2)(1¯2))∊,W}¨¨W←⍳⍵⍵
 +/                                     - The number of ...
                            ∊,W         - ... in-bounds ...
        (⊖,⊢)(⊢,-)(⍳2)(1¯2)             - ... knight movements ...
   (⍵∘+¨                   )            - ... from ...
{                              }¨¨W←⍳⍵⍵ - ... each square

Python 2, 114 103 92 bytes
lambda n:[sum((d*c>d)+(d*c>c)for d in(y%n,n-y%n-1)for c in(y/n,n-y/n-1))for y in range(n*n)]

Try it online!

Retina, 161 bytes
.+
*
L$`_
$=
(?<=(¶)_+¶_+)?(?=(?<=(¶)_*¶_*)__)?(?<=(¶)__+)?(?=(?<=(¶)_*)___)?_(?=(?<=___)_*(¶))?(?=__+(¶))?(?=(?<=__)_*¶_*(¶))?(?=_+¶_+(¶))?
$.($1$2$3$4$5$6$7$8)

Try it online! Link includes test cases. Explanation:
.+
*

Convert to unary.
L$`_
$=

List the value once for each _ in the value, i.e. create a square.
(?<=(¶)_+¶_+)?
(?=(?<=(¶)_*¶_*)__)?
(?<=(¶)__+)?
(?=(?<=(¶)_*)___)?
_
(?=(?<=___)_*(¶))?
(?=__+(¶))?
(?=(?<=__)_*¶_*(¶))?
(?=_+¶_+(¶))?

Starting at the _ in the middle of the regex, try to match enough context to determine whether each of the eight knight's moves is possible. Each pattern captures a single character if the match succeeds. I tried using named groups so that the number of captures directly equals the desired result but that cost 15 bytes.
$.($1$2$3$4$5$6$7$8)

Concatenate all the successful captures and take the length.

Wolfram Language (Mathematica), 34 bytes
Yet another Mathematica built-in.
VertexDegree@KnightTourGraph[#,#]&

Returns a flattened list.
Try it online!

I actually made a comment under the challenge with this answer (although not correct syntax since I don't know WL). I removed it after a bit, since I figured someone else might want to post it as a real answer.

C (gcc), 133 125 bytes
This solution should work on any size board.
#define T(x,y)(x<3?x:2)*(y<3?y:2)/2+
a,b;f(i){for(a=i--;a--;)for(b=i+1;b--;)printf("%i ",T(a,b)T(i-a,b)T(a,i-b)T(i-a,i-b)0);}

Try it online!

@ceilingcat Of course, thanks! But I don't see what the second suggestion changes

124 bytes