Skip to main content
added 17 characters in body
Source Link
Julian
  • 3.2k
  • 7
  • 17

Alice, 1311 bytes

w.2~E/ O \hK\h

Try it online!Try it online!

The trailing newline is required

w          K   Main loop
 .             Duplicates the top of the stack, or two `0` if the stack is empty
 2~ 2~E          Pushes two on the stack, swap the top two items 
 and calculate E          Calculates `2^n`, where `n` is the current iteration minus 1
     / O \     Prints the number
          h    Increments the exponent

Alice, 13 bytes

w.2~E/ O \hK

Try it online!

The trailing newline is required

w          K   Main loop
 .             Duplicates the top of the stack, or two `0` if the stack is empty
  2~E          Pushes two on the stack, swap the top two items and calculate `2^n`, where `n` is the current iteration minus 1
     / O \     Prints the number
          h    Increments the exponent

Alice, 11 bytes

.2~E/ O \h

Try it online!

The trailing newline is required

.             Duplicates the top of the stack, or two `0` if the stack is empty
 2~           Pushes two on the stack, swap the top two items 
   E          Calculates `2^n`, where `n` is the current iteration minus 1
    / O \     Prints the number
         h    Increments the exponent
Source Link
Julian
  • 3.2k
  • 7
  • 17

Alice, 13 bytes

w.2~E/ O \hK

Try it online!

The trailing newline is required

w          K   Main loop
 .             Duplicates the top of the stack, or two `0` if the stack is empty
  2~E          Pushes two on the stack, swap the top two items and calculate `2^n`, where `n` is the current iteration minus 1
     / O \     Prints the number
          h    Increments the exponent