make ruby encode more fun ctional
functionalize ruby decode64