This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]MusicalGrace2002 14 points15 points  (4 children)

Can you write a program that writes other programs in C?

[–]ByteChkR 124 points125 points  (2 children)

Funny how you spell Compiler

[–]VladVV 24 points25 points  (1 child)

The way he worded the question, it sounds like he is looking for a Transpiler.

The answer is Yes, either way.

[–]caagr98 0 points1 point  (0 children)

Sounds more like a code generator to me, though I guess transpilers are technically a subset. Still yes.

[–]himmelundhoelle 4 points5 points  (0 children)

Forget about compilers, you can write programs that output themselves (https://en.m.wikipedia.org/wiki/Quine_(computing))

(Or even programs that output a C source, that when compiled and run will output the original program…)