Talk:I like frog
A few questions:
like i, how are ternary numbers converted into bits? Do the inserted bits start at the cell at the pointer or the cell to the right of the pointer? Is the conversion big- or little-endian?
- How are numbers converted into characters for
like frog? A direct base-256 conversion of the argument in the Hello World program yields
Hello,¬:y·ôû, which is obviously incorrect.
- The parameterless
like frogcommand requires a buffer of bits; what happens when
like frogis used with a parameter when the buffer is nonempty?
- What is the general behavior when one jumps to a nonexistent command? The infinite loop program seems to suggest that the IP wraps around.
- There are still several things which need to be specified before an interpreter can be written:
like i, do the inserted bits start at the cell at the pointer or the cell to the right of the pointer?
- How many bits are in one data cell?
- How are the commands translated into binary/hexadecimal for the purposes of
frog i, and
- Are bits rotated left or right?
- Does the IP wrap around for
- I count 10 commands including newline. Where are the other 6?
- LegionMammal978 (talk) 15:23, 24 April 2020 (UTC)
1. to the right of the pointer.
2. 8 bits.
3. The translations go as follows:
(F marks end of command and params)
i (w/o like or frog) => 0F
i like (params) => 1(params)F
i like (no params) => 2F
i frog (params) => 3(params)F
i frog (no params) => 4F
like (w/o i or frog) => 5F
like i (params) => 6(params)F
like i (no params) => 7F
like frog (params) => 8(params)F
like frog (no params) => 9F
frog (w/o i or like) => AF
frog i (params) => B(params)F
frog i (no params) => CF
frog like (params) => D(params)F
frog like (no params) => EF
Params must be in octal with digits 4-B.
4. I forgot to add which way the bits were rotated, check now.
5. Yes, IP always wraps in this language