Polyglot programmes run in more than one programming language at the same time. One example runs in C, PHP, and Bash; another one runs in a ridiculous 282 different languages.
There are a few nice tricks that make this work. For example, most programming languages have a symbol that prevents specific lines from being processed. These symbols are used to add comments and instructions to the code, hints and help for any other programmer who views the code itself. But different languages use different symbols – so what is hidden in one language is visible in another.
That’s just one trick, but clever programmers have dozens of these tricks up their sleeves, and in the link below there’s one programme that works in 282 different languages. Ridiculous!
I live in Auckland, New Zealand, and am curious about most things.