VocabReminder
Easily build a great vocabulary without studying! Now on the App Store!
Click here for more info about the app

Cool Conditional Syntax in Ruby (on Rails)

       

Ruby is beautiful

@posts = if true Post.all else [] end

Simply elegant!

Tagged w/ #beauty #block #conditional #syntaxruby on rails