Folders is a language where the program is encoded into a directory structure. All files within are ignored, as are the names of the folders. Commands and expressions are encoded by the pattern of folders within folders. Source code for the Folders compiler can be found on github.
Like programming languages themselves (which are only lists of rules), the Folders language is dematerialized. Files, the equivalent of "content" within an operating system are gone, leaving only folders, structural elements.
Folders is a Windows language. In Windows, folders are entirely free in terms of disk space! For proof, create say 352,449 folders and get properties on it.
Here is a Hello, World! program:
Each command folder has at least one child folder. The number of subfolders in the first folder (alphabetically) indicates the type of command; any arguments are indicated in a second folder; some commands require a third folder.
In the program above, there is a single command (print), with its argument a string. The string holds "Hello, World!".
The Folders interpreter does not create temp files; anything not held immediately in memory is stored as a set of temp folders in the %appdata% directory. The prefered I/O of Folders is another set of folders. This means you can encode all your data in folders, bypassing the material realm of files entirely.
Here are how the commands and expressions are encoded:Commands
|Command||# of Folders||Details|
|if||0 folders||Second sub-folder holds expression, third holds list of commands|
|while||1 folder||Second sub-folder holds expression, third holds list of commands|
|declare||2 folders||Second sub-folder holds type, third holds var name (in number of folders)|
|let||3 folders||Second holds var name (in number of folders), third holds expression|
|4 folders||Second sub-folder holds expression|
|input||5 folders||Second sub-folder holds var name|
|Type||# of Folders||Details|
|Variable||0 folders||Second sub-folder holds var name|
|Add||1 folder||Second sub-folder holds first expression to add, third holds second expression|
|Subtract||2 folders||Second sub-folder holds first expression to subtract, third holds second expression|
|Multiply||3 folders||Second sub-folder holds first expression to multiply, third holds second expression|
|Divide||4 folders||Second sub-folder holds first expression to divide, third holds second expression|
|Literal Value||5 folders|
|Equal To||6 folders||Second and third folders hold expressions to compare|
|Greater Than||7 folders||Second and third folders hold expressions to compare|
|Less Than||8 folders||Second and third folders hold expressions to compare|
|Type||# of Folders|