wenyan

From Esolang
Jump to navigation Jump to search

wenyan (文言) is a language created by LingDong- in 2019. The language is Turing Complete. Wenyan-lang use classical Chinese as its source code. It currently has multiple backends including JavaScript, Python, and Ruby.

Code Samples

The following codes is Hello world in wenyan-lang. It prints "問天地好在。" to console.

吾有一言。曰「「問天地好在。」」。書之。

This one print Fibonacci sequence from 1 to 10.

有數一。名之曰「代」。
有數零。名之曰「母」。
有數一。名之曰「子」。
有數零。名之曰「实」。

恆為是。若「代」大於十者乃止也。
    加「母」以「子」。昔之「实」者。今其是矣。
    夫「代」,夫「「代:」」,夫「实」,書之。
    昔之「子」者。今「母」是矣。
    昔之「母」者。今「实」是矣。
    加「代」以一。昔之「代」者。今其是矣。
云云。

External resources