Sha256: 1832149fcdd171885b96cd4435e5ddb412f29e3561a731598904c8e0b3d86a5c

Contents?: true

Size: 396 Bytes

Versions: 14

Compression:

Stored size: 396 Bytes

Contents

# This file demonstrates unless and until statements.

# Examples are from http://www.skorks.com/2009/09/a-wealth-of-ruby-loops-and-iterators/ and 
# http://37signals.com/svn/posts/2699-making-sense-with-rubys-unless 

puts "There's no such person" unless person.present?

unless person.present?
   puts "There's no such person" 
end

i=1
until i > 10
  print "#{i} "
  i+=1
  break if i == 9
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
nilac-0.0.4.3.9.8 shark/test_files/unless_until.nila
nilac-0.0.4.3.9.7.1 shark/test_files/unless_until.nila
nilac-0.0.4.3.9.7 shark/test_files/unless_until.nila
nilac-0.0.4.3.9.6 shark/test_files/unless_until.nila
nilac-0.0.4.3.9.5 shark/test_files/unless_until.nila
nilac-0.0.4.3.9.4 shark/test_files/unless_until.nila
nilac-0.0.4.3.9.3 shark/test_files/unless_until.nila
nilac-0.0.4.3.9.2 shark/test_files/unless_until.nila
nilac-0.0.4.3.9.1 shark/test_files/unless_until.nila
nilac-0.0.4.3.9 shark/test_files/unless_until.nila
nilac-0.0.4.3.8 shark/test_files/unless_until.nila
nilac-0.0.4.3.7 shark/test_files/unless_until.nila
nilac-0.0.4.3.6 shark/test_files/unless_until.nila
nilac-0.0.4.3.4 shark/test_files/unless_until.nila