Self-reproducing programs

Quine: a program producing its complete source code as its only output

A Python quine, using repr for escaping

a = 'a = %r\nprint(a %% a)'
print(a % a)

Same thing in JavaScript via JSON formatting

const a = "const a = %s\nconsole.log(a, JSON.stringify(a))"
console.log(a, JSON.stringify(a))

A Java quine, using ASCII codes

package ovh.mvasilkov.java.quine;

public class Program {
    public static void main(String[] args) {
        String a = "package ovh.mvasilkov.java.quine;%11$c%11$cpublic class Program {%11$c";
        String b = "    public static void main(String[] args) {%11$c";
        String c = "        String %c = %12$c%s%12$c;%11$c";
        String d = "%11$c        System.out.printf(a + b + c + c + c + c + c + d + z, ";
        String z = "'a', a, 'b', b, 'c', c, 'd', d, 'z', z, 0xa, 0x22);%11$c    }%11$c}%11$c";

        System.out.printf(a + b + c + c + c + c + c + d + z, 'a', a, 'b', b, 'c', c, 'd', d, 'z', z, 0xa, 0x22);
    }
}

The positional arguments are as follows:

%11$c = 0xa = '\n'
%12$c = 0x22 = '"'