/data_structures

Data structures in Ruby and Scheme - a comparison

Primary LanguageRuby

Functional vs. OO - Common Data Structures

Since I'm working on functional programming, I wanted to build and compare some common data structures in Ruby and Scheme.

Why Scheme?

Scheme seemed as good a functional language as any to dive into functional programming, and there are some sweet 80s video lectures from MIT available online.

For more on Scheme, check out MIT OCW - Structure and Interpretation of Computer Programs

Why Ruby?

Ruby is clearly object-oriented, but it clearly was influenced by Lisp (of which Scheme is a dialect). It's much more feature-rich compared to Scheme, and I enjoy comparing features which I essentially have to build in Scheme to functions available in the Ruby standard library.