Another update from ingydotnet^djgoku
This commit is contained in:
parent
91df62d461
commit
948b86eafa
7604 changed files with 108452 additions and 22726 deletions
|
|
@ -1,8 +1,10 @@
|
|||
p 'abcd'.start_with?('ab') #returns true
|
||||
p 'abcd'.end_with?('ab') #returns false
|
||||
p 'abab'.include?('bb') #returns false
|
||||
p 'abab'.include?('ab') #returns true
|
||||
p 'abab'.index('bb') #returns nil
|
||||
p 'abab'.index('ab') #returns 0
|
||||
p 'abab'.index('ab', 1) #returns 2
|
||||
p 'abab'.rindex('ab') #returns 2
|
||||
p 'abcd'.start_with?('ab') #returns true
|
||||
p 'abcd'.end_with?('ab') #returns false
|
||||
p 'abab'.include?('bb') #returns false
|
||||
p 'abab'.include?('ab') #returns true
|
||||
p 'abab'['bb'] #returns nil
|
||||
p 'abab'['ab'] #returns "ab"
|
||||
p 'abab'.index('bb') #returns nil
|
||||
p 'abab'.index('ab') #returns 0
|
||||
p 'abab'.index('ab', 1) #returns 2
|
||||
p 'abab'.rindex('ab') #returns 2
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue