troubleshooting Question

Ruby string manipulation, easy enough?

Avatar of Jace5
Jace5 asked on
Windows XPWindows OSRuby
5 Comments1 Solution2614 ViewsLast Modified:
I need to work with this string to return only the numbers...

$Name just deposited 20000000 in the bank.

I need to remove $Name just deposited and in the bank.

returning only:
20000000

Now please note that the deposit will change so if I can chomp off the name variable and the last of it that would be great.

$Name of course changes from person to person.

So something like deposit = $depstring.chomp($Name, " just deposited  ", " in the bank")

would be ideal I just cant figure out the syntax.
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 5 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 5 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros