Ruby

Ruby Parameter Passing: A Quick Reference

Ruby Variables: A Quick Reference This is meant to be a quick reference to bookmark if you don’t work on Ruby code all that often, it’s not meant to be a deep dive into the language Passing Values into Functions There are several ways to pass values into functions. Regular Parameter Passing This is the standard way of doing things, and it looks like this: def foo(val1, val2) puts val1 puts val2 end def bar() foo("Hello,", "World") end bar() output:

Read more →

Linked Lists Compared

Linked Lists Functional, Procedural, and Object Oriented; Part 1 Over the last 2 weeks, I’ve been building a singly linked list implementation from scratch in Haskell, Ruby, and C. I originally did it just to become a little bit more sharp in these languages, but what I found was really interesting, so I thought I would share my findings in a blog post. What is a Linked List? A linked list is one of the most foundational data structures in computer science.

Read more →