Epic codefest: 7 programming languages in 7 days

We challenged our developers to learn Clojure, Scala, JavaScript, Ruby, Java, Kotlin, and Go in a day. Here's how easy it is to make the switch

Page 4 of 9

Day three: Ruby Granny
Developer: Brian Crucitti, "The New Guy"

What makes Ruby special for this particular type of development is Rails, a framework for Ruby that I'm sure most people have heard of. Once I had a basic grasp of Rails, putting this application together was incredibly easy.

I installed Ruby and Rails; three Rails commands later, I had a basic app outline and database. Getting the main page set up took me a moment of searching through the new directory and replacing the existing public/index.html with my own code. After that, a bit of trial, error, and code analysis allowed me to set my JavaScript file to accurately communicate with the Ruby back end.

I didn't have many questions or trip-ups making the app. In preparation, I studied the Rails tutorial. The first few chapters were enough for me to set up almost all of the Ruby aspects of Granny's Addressbook.

I would definitely recommend using Ruby for all sorts of projects. It's a language that's very easy to read and write. I would definitely recommend using Ruby and Rails for Web applications, especially small ones.

If I had to write a similar application again, I would definitely choose to write it in Ruby over just about any other option, especially with Rails. It was so easy to set up the basic outline of the app, which is all a Granny-level app really needs.

The one drawback to this project is that I don't feel like I learned very much Ruby. I learned several Rails commands, which did all the work in creating the Ruby files for me. As I've stated before, this project was very simple to achieve using Ruby and Rails. I'm sure there's a wealth of powerful abilities in Rails and Ruby, but it wasn't called for here. I'd like to study them more.

For development, I used TextWrangler for the Mac because I like text highlighting and it has a convenient method of switching between files in a directory tree. I ordinarily use Notepad++ for Windows, and TextWrangler had a similar feel.

| 1 2 3 4 5 6 7 8 9 Page 4
From CIO: 8 Free Online Courses to Grow Your Tech Skills
Notice to our Readers
We're now using social media to take your comments and feedback. Learn more about this here.