Created
March 21, 2012 13:37
-
-
Save sr75/2146937 to your computer and use it in GitHub Desktop.
parse decimal from string example method
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
def parse_decimal_from_string(value) | |
value.scan(/[-+]?\d*\.?\d+/).join('') | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment