From Esolang
Jump to navigation Jump to search
This article is not detailed enough and needs to be expanded. Please help us by adding some more information.
This is still a work in progress. It may be changed in the future.

Capitalsim is a programming language created in 2023 based on the idea of capitalism and wage labor, partially based on Haczyk. Capitalsim and Haczyk will probably be developed in parallel due to the similarities between the two, and due to Haczyk being a simpler language than Capitalsim in terms of programming.

Notably, a lot of aspects of Capitalsim are arbitrary and may not be a good representation of wage labor. You are free to create a language that more accurately simulates capitalism and then ask me for the name "Capitalsim", in which case I will call this language something else.


You can split this language into data, variables, keywords, and functions.


The data consists of characters, unbounded integers, strings, and mutable tuples of those things. The tuples can contain any other data structure, including other tuples, but can only have two data structures inside of them.


There is a set of keywords which allows for control flow.


  • if(CONDITION) - endif
    • checks if a condition
  • now(CONDITION) - endnow
    • normal while loop
    • if the condition is false, go to endnow
    • else, loops over a specific code block and checks the condition at a specific time, going to the end if false
  • always(CONDITION) - endalways
    • if the condition is false, go to endalways
    • else, loops over a specific code block and checks the condition every line, breaking if false


Variables are initialized with

  • data, which is the actual thing they represent
  • power, which has nothing to do with the actual program
    • it can be split into multiple aspects
      • something which represents the kind of power it is
      • a bounded integer represents their maximum power, where the variable starts at maximum power
      • a much smaller bounded integer representing how often the base power goes up
      • a much smaller bounded integer representing the amount the base power goes up each time it goes up
    • the power is generated randomly
    • the power may not even be useful in the context of the program, which leads to unemployment
    • the worker can have multiple powers
  • work ethic, which controls how much power they are willing to use and/or the desired lower bound of their power
    • it varies based on each power
  • desire for power, which controls how much power they take from their workers if they have any
    • it varies based on each power

The variables initialized earlier get to option to randomly take the data of the variables initialized later every time they are initialized later, incorporating them into a tuple which consists of the first variable's previous data followed by the newly-obtained data. This variable is now a capitalist.

Variables become workers when:

  • they are set to the value of another variable
  • their data is taken by another variable
  • it gives ownership of its data to another variable

(This also means the language is unambiguously pass-by-reference in every case, never pass-by-value.)

Once a variable becomes a capitalist, it is temporarily free from being turned into a worker, and can only turn into a worker if it goes into debt and has to sell its data to another capitalist.

Every time a new line is read, the worker has to pay the capitalist who holds its data at least 1 dollar. The more hands it has to go through, the more dollars it has to pay. The capitalists can all randomly decide to raise prices by 1 dollar. The capitalists can also lower prices if they are not getting money. Prices go up over time due to inflation, which is dependent on the dollars in the economy.

The worker has to find a capitalist who wants its power, which may or may not be the capitalist who holds its data. The The capitalist who wants the power causes the variable's power stat to decrease by a certain amount and pays the worker money in dollars, and the worker pays the capitalist who has the necessary data the money to actually do the thing it is supposed to do.

The worker doesn't know when it will be called, so it is constantly working in case it gets called. Depending on its work ethic, it may switch to working for a different capitalist.


  • Data = Means of production
  • Variables = Actors in the market
  • Power - labor power
  • dollars - fiat currency

Reminders to Self

  • The dollars are an abstraction for power, so they are not the same thing.
  • Monopolies should be bad. Are they bad?

What May Need to be Created

  • Bank:
    • it creates dollars
    • the variable has to go to the bank to get dollars
    • capitalists earn dollars by getting other variables to pay them
    • workers get dollars by doing what the capitalists want
    • is a bank necessary?
    • Problem: who runs the bank? when is the bank created? can the programmer affect the bank?
  • Takeover
    • One capitalist takes over another capitalist
    • The first capitalist gets the data, and the second capitalist gets a bunch of dollars
    • Problem: When should this happen?
  • Stuff that Variables have
    • All variables are initialized with some amount of power.
    • Power allows the workers to do what the capitalists want.
      • How many flavors of power should there be?
      • How fast should power be replenished?
      • I think the specific kind of power should be partially defined by variable name, as in Haczyk. How should it be defined by that?
    • Should there be other variables like power?