Skip to content

Instantly share code, notes, and snippets.

View 0x0dea's full-sized avatar

D.E. Akers 0x0dea

  • North Carolina, US
View GitHub Profile
@baweaver
baweaver / reverse_lambda.rb
Created June 30, 2015 07:11
Here we go again!
(___=->_,__=''{__=_[$.]+__; _[$.+=$$/$$]?___[_,__]:__})['yllis os']
(___ = # So he's defining a lambda that can be self-called
-> _, __ = '' { # with two args, one is the string and the other is an accumulator
# We're taking the first character and putting it ahead of the accumulator and
# setting it as the next accumulator
#
# $. is 0 (normally, IRB has it as 1, it's ARGF.lineno)
__ = _[$.] + __