Last week, I deployed my first web applications, a big moment in any developer’s life. One app, a guestbook for my friend’s wedding, was written in Ruby, dependent on the Sinatra gem and deployed through Heroku. It consisted of a simple form where friends and family could leave messages for the happy couple. I excitedly… Read More
1 comment
0 comments
A Beginner’s Guide To RSpec
RSpec is a behavior-driven testing tool for the Ruby language. RSpec is used in test driven development (“TDD”), where the developer writes the test based on what s/he hopes the program will accomplish, and then creates the program to accomplish the goals of the test. While this would seem to create additional work for the… Read More
11 comments
Nested Arrays, Hashes & Loops in Ruby
Arrays and hashes are common data types used to store information. The main difference between an array and a hash is the manner in which data is stored. Arrays, represented by square brackets, contain elements which are indexed beginning at 0. So if an array contained three elements, the indexes for those elements would be… Read More
0 comments
Mixin Ruby Modules
Modules are collections of methods and constants. Practically, they’re like a toolbox full of neat tools and supplies. If you wanted to build a house, you might use one set of tools and supplies, whereas building electronics may require another set of tools and supplies. Modules are a way to organize your tools and supplies into useful receptacles.
0 comments
Ruby Classes
Classes are useful to help organize objects with similar attributes and methods. Instead of defining multiple objects with similar attributes, we can instead define a single class and create instances of that class.
2 comments
FizzBuzz in Ruby (and the Strangeness of Ruby Loops)
Comparing Ruby and C.