()()(())

From Esolang
Jump to navigation Jump to search

()()(()) is another bracket esolang. YAAY. It was created by User:Yayimhere

memory

memory is stored in a unbounded binary accumulator

definitions

backend

the first byte in the accumulator

front end

the last byte in the accumulator

nesting

the amount of brackets inside a pair of brackets

syntax

  • a single () with no nesting will append a 1 to the frontend.
  • a () with a nesting N will delete the backend and append it to the frontend N times.
  • a (()()) will do the code in the first brackets as many times as the nesting of the second pair(this includes if inside there is a list of brackets it will just take the full sum of the nesting).
  • a (()()()) will do the same as (()()) but it will do the third pair if and only if the frontend is not 0.
  • ()(())() will flip the frontend and add a 0 as many times as the nesting N of the second brackets. It will also add a 1 to the backend.
  • ((()())) Will for every 1 in the accumulator it will nest the second brackets itself once and for every 0 it will de-nest itself once.
  • ((()(())())()()) Will do whats in the second brackets as long as the nesting N of the second bracket is not equal to the length of the accumulator
  • And last but not least ((())()) Will ignore the first brackets and do whats in the second brackets as long as the back or frontend is not 0

errors

If the brackets are not balanced it will give an error

examples

looping counter(using 1 instead of *):

((())(()))