Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon.

Pages: 1-

Brainhug

Name: Anonymous 2009-11-26 1:05

I had an idea for a programming language and was wondering if it was turing complete. It's basically Brainfuck but instead of the brackets it has these 2:
? put current location in memory into memory, i.e. *ptr = ptr to fit with wikipedia's explanation of brainfuck's operators
! move execution pointer to location specified by *ptr

Then, instead of a completely blank memory, it would be:
[source of program in ASCII] ++ [free memory]
and ptr would start at the first point of free memory. However, all memory will be editable, including the source. This allows for run-time code creation. The program will continue to execute until it reached a null location in memory.

Assuming the first free memory location is 0, here's an infinite loop:
!

Hello World:
<<<<<<<<<<<.>.>.>.>.>.>.>.>.>.>.Hello World

Larger loop (PROTIP: '"' = chr(34)):
<! never reached  do de do       >!"

It seems like it would be pretty easy to make a Quine since the source code's available in memory, but I haven't figured out a way.

Anyway, in this thread program in Brainhug and wonder if it's turing complete.

Name: Anonymous 2009-11-26 2:56

who the fuck cares

Name: Anonymous 2009-11-26 5:32

Read SICP

Name: Anonymous 2010-11-26 5:29

<

Name: Anonymous 2011-02-04 18:58

Name: Anonymous 2011-02-04 19:35

Don't change these.
Name: Email:
Entire Thread Thread List