Elliott Hird on Sun, 16 Nov 2008 14:39:48 -0700 (MST)


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

[s-b] Brainfuck via Platonic Automation of Contract Obligation


I create and join the following contract:
{{{
For each positive integer N, Cell N is a Thing. These may be  
collectively
referred to as "Cells".

There is an Attribute with the Name of "Contents", a Scope of Cells,  
a Range of
all integers from 0 to 255 and a Default Value of 0.

There is an Attribute with the Name of "Step", a Scope of parties to  
this
contract, a Range of all positive integers (including 0) and a  
Default Value of
0.

There is an Attribute with the Name of "Pointer", a Scope of parties  
to this
contract, a Range of all positive integers (including 0), and a  
Default Value of
0.

There is an Attribute with the Name of "Output", a Scope of parties  
to this
contract, a Range of all ASCII strings and a Default Value of "".

There is an Attribute with the Name of "Input", a Scope of parties to  
this
contract, a Range of all ASCII strings and a Default Value of "".

Parties to this contract can change the value of the Contents  
attribute of any
Cell as a Game Action.

Parties to this contract can change the value of their Step attribute  
as a Game
Action.

Parties to this contract can change the value of their Pointer  
attribute as a
Game Action.

Parties to this contract can change the value of their Input  
attribute as a
Game Action.

Parties to this contract can change the value of their Output  
attribute as a
Game Action.

Nobody apart from ehird can join this contract.

A party's "Current Cell" means "Cell N, where N is the Contents of  
the party's
Pointer attribute".

"BF-Incrementing" a Cell means "if the Contents of the cell is 255,  
then set the
Contents of the cell to 0; otherwise, increment the Contents of the  
cell by 1".

"BF-Decrementing" a Cell means "if the Contents of the cell is 0,  
then set the
Contents of the cell to 255; otherwise, decrement the Contents of the  
cell by
1".

A party "BF-Outputting" a Cell means "appending the Contents of the cell
treated as an ASCII character number to the party's Output attribute".

A party "BF-Inputting" to a Cell means "setting the Contents of the  
cell to the
ASCII character number of the first character in the value of the  
party's Input
attribute and removing the first character from the party's Input  
attribute".

When a party's Step is 0, they must increase the value of their Pointer
attribute by 1 and set their Step to 1. When a party's Step is 1,  
they must
BF-Increment their Current Cell and set their Step to 2. When a  
party's Step is
2, they must BF-Increment their Current Cell and set their Step to 3.  
When a
party's Step is 3, they must BF-Increment their Current Cell and set  
their Step
to 4. When a party's Step is 4, they must BF-Increment their Current  
Cell and
set their Step to 5. When a party's Step is 5, they must BF-Increment  
their
Current Cell and set their Step to 6. When a party's Step is 6, they  
must
BF-Increment their Current Cell and set their Step to 7. When a  
party's Step is
7, they must BF-Increment their Current Cell and set their Step to 8.  
When a
party's Step is 8, they must BF-Increment their Current Cell and set  
their Step
to 9. When a party's Step is 9, they must BF-Increment their Current  
Cell and
set their Step to 10. When a party's Step is 10 and the Contents of  
their
Current Cell is 0, they must set their Step to 23. When a party's  
Step is 10 and
the Contents of their Current Cell is not 0, they must set their Step  
to 11.
When a party's Step is 11, they must decrease the value of their Pointer
attribute by 1 and set their Step to 12. When a party's Step is 12,  
they must
BF-Increment their Current Cell and set their Step to 13. When a  
party's Step is
13, they must BF-Increment their Current Cell and set their Step to  
14. When a
party's Step is 14, they must BF-Increment their Current Cell and set  
their Step
to 15. When a party's Step is 15, they must BF-Increment their  
Current Cell and
set their Step to 16. When a party's Step is 16, they must BF- 
Increment their
Current Cell and set their Step to 17. When a party's Step is 17,  
they must
BF-Increment their Current Cell and set their Step to 18. When a  
party's Step is
18, they must BF-Increment their Current Cell and set their Step to  
19. When a
party's Step is 19, they must BF-Increment their Current Cell and set  
their Step
to 20. When a party's Step is 20, they must increase the value of  
their Pointer
attribute by 1 and set their Step to 21. When a party's Step is 21,  
they must
BF-Decrement their Current Cell and set their Step to 22. When a  
party's Step is
22 and the Contents of their Current Cell is 0, they must set their  
Step to 10.
When a party's Step is 22 and the Contents of their Current Cell is  
not 0, they
must set their Step to 23. When a party's Step is 23, they must BF- 
Increment
their Current Cell and set their Step to 24. When a party's Step is  
24, they
must BF-Increment their Current Cell and set their Step to 25. When a  
party's
Step is 25, they must BF-Increment their Current Cell and set their  
Step to 26.
When a party's Step is 26, they must BF-Increment their Current Cell  
and set
their Step to 27. When a party's Step is 27, they must BF-Increment  
their
Current Cell and set their Step to 28. When a party's Step is 28,  
they must
BF-Increment their Current Cell and set their Step to 29. When a  
party's Step is
29, they must BF-Increment their Current Cell and set their Step to  
30. When a
party's Step is 30, they must increase the value of their Pointer  
attribute by 1
and set their Step to 31. When a party's Step is 31, they must BF- 
Decrement
their Current Cell and set their Step to 32.
}}}
_______________________________________________
spoon-business mailing list
spoon-business@xxxxxxxxx
http://lists.ellipsis.cx/mailman/listinfo/spoon-business