Show Menu

Strings in ruby Cheat Sheet by

Strings in ruby
development     programming     ruby     string

Strings in ruby

Name
Example
Interp­olated?
' '
'string'
" "
"­str­ing­"
yes
% notation
%[string]
only without or with Q modyfier
"Here docume­nt" notation
<<HERE
yes
 
string
 
HERE
 

Percentage notation

Name
Example
Interp­olated
Q
%Q[]
yes
q
%q[]
no
 

Here document

<<D­ELI­MITER
some string
' ' "­str­ing­" can have
#{inte­rpo­lat­ed_­var­iable}
DELIMITER
with '-' ending delimiter can start with spaces
<<-­DEL­IMITER
text
_DELIMITER
Underscore used instead of space

Download the Strings in ruby Cheat Sheet

1 Page
//media.cheatography.com/storage/thumb/nedzadarek_strings-in-ruby.750.jpg

PDF (recommended)

Alternative Downloads

Share This Cheat Sheet!

 

Comments

No comments yet. Add yours below!

Add a Comment

Your Comment

Please enter your name.

    Please enter your email address

      Please enter your Comment.

          Related Cheat Sheets

          Regular Expressions Cheat Sheet
          vim-rails Cheat Sheet