Skip to main content
added 540 characters in body
Source Link
Noodle9
  • 20.3k
  • 3
  • 21
  • 46

Bash, 2525 22 bytes

f(){(
echo $((1<<++a)$[1<<a++];f);f
}

Try it online!

Saved 3 bytes thanks to Digital Trauma

Solution of Digital Trauma's:

Bash, 18 bytes

echo $1
$0 $[$1*2]

Try it online!Try it online!

Bash, 25 bytes

f(){
echo $((1<<++a));f
}

Try it online!

Bash, 25 22 bytes

f()(
echo $[1<<a++];f)

Try it online!

Saved 3 bytes thanks to Digital Trauma

Solution of Digital Trauma's:

Bash, 18 bytes

echo $1
$0 $[$1*2]

Try it online!

Source Link
Noodle9
  • 20.3k
  • 3
  • 21
  • 46

Bash, 25 bytes

f(){
echo $((1<<++a));f
}

Try it online!