In this episode we create a function for converting arbitrary values into Feet objects.
Month: May 2014
Episode #206: Coercion
Ruby generally doesn't allow mixing of types without explicit conversion. So have you ever wondered why it's possible to multiply 2.3 (a float) by 5 (an integer)? In today's episode …
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.
Episode #202: Identity And Equality
Today's episode deals with the concepts of identity and equality - what makes one object equal to another.
Episode #201: Immutable Object
In this episode we learn how mutability can lead to bugs in Value Objects... and how we can eliminate these types of bugs once and for all.
Episode #200: Quantity
In today's episode we take a look at a storied problem in software: defects caused by accidentally mixing-up the units of measurement used in calculations. And we kick off a …
Episode #199: Regexp Union
Today's episode demonstrates an easy way to build big regular expressions out of little ones.