Regular expressions (regexps) are patterns which describe the contents of a string. They’re used for testing whether a string contains a given pattern, or extracting the portions that match. They are created with the /pat/ and %r{pat} literals or the Regexp.new constructor.| ruby-doc.org
Public Instance Methods| ruby-doc.org
Public Class Methods| ruby-doc.org
A String object has an arbitrary sequence of bytes, typically representing text or binary data. A String object may be created using String::new or as literals.| ruby-doc.org