Created
July 13, 2014 03:26
-
-
Save abali96/8422a826b7a782776db7 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if operands.each {|operand| operand[0] == "-"} | |
x = operands.shift | |
puts operands | |
pre_arguments = '"' + operands.join('", "').gsub(/-/, '') + '"' | |
add(x, pre_arguments) | |
end | |
# the add method accepts arguments as strings like add("1", "2", "3") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment