In today's episode, we'll compare two methods for getting to the body of an email: one imperative; one functional; and both idiomatic Ruby.
Tag: containers
Episode #232: Range
Good morning diners! On today's menu, we have a deep exploration of Ruby's Range type. Even if you've used ranges before, you might find something new to chew on. Enjoy!
Episode #225: Unitwise
As our series on representing physical quantities draws to a close, we turn our attention to existing libraries, specifically the Unitwise gem.
Episode #224: Surrogate Ordering
It's often desirable compare objects to see which is "lesser" or "greater"; but not all objects are inherently comparable. Today we'll look at a scheme for easily imposing an arbitrary …
Episode #218: Spaceship Revisited
In episode 205 we introduced the spaceship () operator, but we also introduced an incompatibility with how Ruby's builtin comparisons work. Today we'll address this oversight.
Episode #205: Comparable
In this episode we meet a Ruby standard module that makes it easy to make classes comparable and sortable.
Episode #204: Hash Equality
Building on the previous episode on hash tables, today we tackle the concept of hash equality: how Ruby decides if two objects are the same for the purpose of use …
Episode #203: Hash Table
Today's dish is an exploration of how Ruby is able to quickly look up keys in hashes.