Skip to main content
2 of 8
added 691 characters in body
SnoringFrog
  • 1.8k
  • 19
  • 13

#Whitespace, Brainfuck, Ruby, Labyrinth: 32 bytes / 4^3 = .5 bytes

Legend:

£: tab

: space

puts•2;#4!@ -[>+<-----]>.•£ £ •£ 

##Explanation:

###Whitespace

(omitting ignored characters)

spacespacespacetabenter: push a 1 onto the stack

tabenterspacetab: output the top of the stack

###Ruby

Shouldn't need explaining. Prints 2, treats the rest of that line (ergo, the brainfuck program) as a comment, treats the rest of the file as empty.

###Brainfuck

Requires an interpreter that supports underflow. Underflows the first cell to 255 then uses that for a loop counter to generate 51, which is the ascii code for 3.

###Labyrinth

(omitting the last two lines for legibility because they are never reached)

puts•2;#4!@ -[>+<-----]>.•£ puts• skipped 2 push 2 onto stack ; pop 2 from stack # push current stack depth (0) to stack 4 push 4 to stack ! print top of stack as integer @ program terminates 
SnoringFrog
  • 1.8k
  • 19
  • 13