Wow, right when you’re beginning to feel comfortable with one language, your world gets flipped upside-down. Today we started working with Ruby, and although I took General Assembly’s back-end web development class a few months ago, I realize I never really quite absorbed the information.
We reviewed how Ruby is different than JavaScript, how the syntax is a bit different as well as the way to debug the language (i.e. using puts instead of console.log) and gathering user input (i.e. gets).
In the afternoon we reviewed Ruby enumerables, also known as methods to search, sort, and manipulate collections. We learned that Ruby deals with arrays as well as hashes (which are like JavaScript objects) and went over the various ways of looping that include:
- for … in
- while
- until
- loop do
- .times
Afterwards, the class jumped on the homework assignments, and it was definitely a struggle. For the first time, it looks like I won’t be able to complete mine. However, I’m refusing to give up just yet. Hopefully I can make sense of this soon…
Resources