esolang

Weeeeeeeeeeeeeeeeeeeeeeeeeeeeee

An epidemic on one accumulator, one infected person at a time.

Yes, 2022 · Turing complete: no · ●○○ easy · esolangs.org

Tested with 2 known programs · Test method

Run it

Expected: x

The idea

The user Yes made this language in 2022 around virus epidemics. The accumulator counts the infected, from 0 to 255. There is no loop command, so printing a letter means one line of Infect person for every step up. The program that says Hi is 153 lines long. It counts to 72 for the H and then to 73, so it prints HI in capitals.

The machine

LineDoes
Start epidemicMust be the first line
Infect personAdd one
Deinfect personTake one away
Bulk infectRead one byte of input
Check number of infectionsPrint the accumulator as a byte
Bulk deinfectSet it to 1 if above 0, else 0
Skip next if no one infectedSkip the next line if it is 0
Delevop vaccineEnd the program

The specification calls its skip example an infinite loop, sort of. So this implementation starts again from the top after the last line, and a program stops only at Delevop vaccine.

Example

The first program is the one time cat.
Expected: A

The first program is the one time cat. The second prints the byte it reads only when it is not 0.

Further

Ideas it shows

Accumulator-based

Write your own in Run Convert a program from Weeeeeeeeeeeeeeeeeeeeeeeeeeeeee

Implementation

JavaScript interpreter, source and command line

A JavaScript interpreter, used in the browser and on the command line. Id: weeeeeeeeeeeeeeeeeeeeeeeeeeeeee.

Command line

shib run weeeeeeeeeeeeeeeeeeeeeeeeeeeeee -e 'Start epidemic
Bulk infect
Check number of infections
Delevop vaccine' --input 'x'
shib manual weeeeeeeeeeeeeeeeeeeeeeeeeeeeee

Source

Module
langs/wiki/ports.js
Interpreter
langs/wiki/weeeeeeeeeeeeeeeeeeeeeeeeeeeeee.js

Docs: Kernel instructions · The .shib format · Command line · Adding a language

Source esolangs.org (CC0) · Edit on esolangs.org