πŸ†‚πŸ†€πŸ†„πŸ…°πŸ†πŸ…΄.πŸ…ΉπŸ†‚

From Esolang
Jump to navigation Jump to search

πŸ†‚πŸ†€πŸ†„πŸ…°πŸ†πŸ…΄.πŸ…ΉπŸ†‚ is a joke language.

Commands

Every single one of JavaScript.

Examples

Hello, World!

πŸ…²πŸ…ΎπŸ…½πŸ†‚πŸ…ΎπŸ…»πŸ…΄.πŸ…»πŸ…ΎπŸ…Ά("πŸ…·πŸ…΄πŸ…»πŸ…»πŸ…Ύ, πŸ††πŸ…ΎπŸ†πŸ…»πŸ…³")

Hello, World! (alert())

πŸ…°πŸ…»πŸ…΄πŸ†πŸ†ƒ.πŸ…»πŸ…ΎπŸ…Ά("πŸ…·πŸ…΄πŸ…»πŸ…»πŸ…Ύ, πŸ††πŸ…ΎπŸ†πŸ…»πŸ…³")

Fibonacci

πŸ†…πŸ…°πŸ† πŸ…Έ;
πŸ†…πŸ…°πŸ† πŸ…΅πŸ…ΈπŸ…± = [0, 1]; // πŸ…ΈπŸ…½πŸ…ΈπŸ†ƒπŸ…ΈπŸ…°πŸ…»πŸ…ΈπŸ†‰πŸ…΄ πŸ…°πŸ†πŸ†πŸ…°πŸ†ˆ!

πŸ…΅πŸ…ΎπŸ† (πŸ…Έ = 2; πŸ…Έ <= 10; πŸ…Έ++) {
  // πŸ…½πŸ…΄πŸ†‡πŸ†ƒ πŸ…΅πŸ…ΈπŸ…±πŸ…ΎπŸ…½πŸ…°πŸ…²πŸ…²πŸ…Έ πŸ…½πŸ†„πŸ…ΌπŸ…±πŸ…΄πŸ† = πŸ…ΏπŸ†πŸ…΄πŸ†…πŸ…ΈπŸ…ΎπŸ†„πŸ†‚ + πŸ…ΎπŸ…½πŸ…΄ πŸ…±πŸ…΄πŸ…΅πŸ…ΎπŸ†πŸ…΄ πŸ…ΏπŸ†πŸ…΄πŸ†…πŸ…ΈπŸ…ΎπŸ†„πŸ†‚
  // πŸ†ƒπŸ†πŸ…°πŸ…½πŸ†‚πŸ…»πŸ…°πŸ†ƒπŸ…΄πŸ…³ πŸ†ƒπŸ…Ύ πŸ…ΉπŸ…°πŸ†…πŸ…°πŸ†‚πŸ…²πŸ†πŸ…ΈπŸ…ΏπŸ†ƒ:
  πŸ…΅πŸ…ΈπŸ…±[πŸ…Έ] = πŸ…΅πŸ…ΈπŸ…±[πŸ…Έ - 2] + πŸ…΅πŸ…ΈπŸ…±[πŸ…Έ - 1];
  πŸ…²πŸ…ΎπŸ…½πŸ†‚πŸ…ΎπŸ…»πŸ…΄.πŸ…»πŸ…ΎπŸ…Ά(πŸ…΅πŸ…ΈπŸ…±[πŸ…Έ]);
}

Interpreter

https://codepen.io/PatoFlamejanteTV/pen/PwYYZpV

<h2>Input (πŸ†€πŸ††πŸ…΄...)</h2>
<textarea id="inputField" rows="4" cols="50"></textarea>

<button onclick="mapAndExecute()">Map & Execute</button>

<h2>Output (js code)</h2>
<textarea id="outputField" rows="4" cols="50" readonly></textarea>
function mapAndExecute() {
    // Reversed Mapping object: special characters to standard keyboard characters
    const charMap = {
        'πŸ†€': 'q', 'πŸ††': 'w', 'πŸ…΄': 'e', 'πŸ†': 'r', 'πŸ†ƒ': 't', 'πŸ†ˆ': 'y', 'πŸ†„': 'u', 'πŸ…Έ': 'i', 'πŸ…Ύ': 'o', 'πŸ…Ώ': 'p',
        'πŸ…°': 'a', 'πŸ†‚': 's', 'πŸ…³': 'd', 'πŸ…΅': 'f', 'πŸ…Ά': 'g', 'πŸ…·': 'h', 'πŸ…Ή': 'j', 'πŸ…Ί': 'k', 'πŸ…»': 'l',
        'πŸ†‰': 'z', 'πŸ†‡': 'x', 'πŸ…²': 'c', 'πŸ†…': 'v', 'πŸ…±': 'b', 'πŸ…½': 'n', 'πŸ…Ό': 'm'
    };

    // Get the input field value
    const inputField = document.getElementById("inputField");
    const inputValue = inputField.value;

    // Map special characters back to standard characters
    let jsCode = '';
    for (let char of inputValue) {
        jsCode += charMap[char] || char; // If char is not in map, use original char
    }

    // Display the JS code
    document.getElementById("outputField").value = jsCode;

    // **WARNING: USING EVAL() WITH UNSAFE INPUT CAN BE DANGEROUS**
    // Execute the JS code (for demonstration purposes only)
    try {
        eval(jsCode);
    } catch (e) {
        console.error("Error executing JS code:", e);
        alert("Error executing JS code. Check console for details.");
    }
}