Somtetimes you need to know if exactly one element in a collection has a given property. For that situation, we have the #one? predicate method.
Month: January 2013
Episode #043: Exclusive Or
This episode looks at Ruby's logical XOR operator, and how it can be useful in checking that a method was called with the correct optional arguments.
Episode #042: Streaming
Does code optimized for RAM usage need to be ugly? Find out, in today's episode!
Episode #041: String#scan
Today's episode looks at a convenient tool for weeding through text and pulling out parts that match a given pattern.