I can’t do most of these yoga poses right now (because of the whole colectomy surgery thing), but here’s a nice list of 12 yin yoga poses to awaken dormant energy and stuff.
Scala, Java, Unix, MacOS tutorials (page 123)
“There’s only ONE rule, but it’s an important one: all of your values must be functions. Not programming functions, but math functions.”
I think I read that quote in an earlier version of this article. The quote is about functional programming, and it influenced something I wrote in my book, Functional Programming, Simplified: Functional programmers think about themselves as being mathematicians, and think of their code as being a combination of algebraic equations, where each function is a pure function that you can think of in mathematical terms.
From eso.org: “Observations made with ESO’s Very Large Telescope have for the first time revealed the effects predicted by Einstein’s general relativity on the motion of a star passing through the extreme gravitational field near the supermassive black hole in the centre of the Milky Way. This long-sought result represents the climax of a 26-year-long observation campaign using ESO’s telescopes in Chile.”
Straight out of high school in Illinois I made the decision to go to a college in Kentucky. In high school I had never known anyone with a southern accent, so it was really neat to hear everyone talk. (I had also never seen a revival tent, but that’s a story for another time.)
One guy at school — I think his name was Joe — came from Tennessee. He would later become famous for loudly chasing his roommate down our dorm hallway with a baseball bat at 2am because he thought the roommate was too loud when he came back in after a night out.
Joe’s accent was so thick I could barely understand what he was saying, and one day in something of a Seinfeld skit I ended up going to the shopping mall with him just because I would nod my head “yes” and say things like “uh-huh” when I didn’t understand him. Fortunately this was before he attacked his roommate with the bat, and his roommate had a sweet 1950s car that we borrowed, so it was a fun ride, even if I didn’t understand most of it.
Now I think there’s at least a slight chance that Joe might be my new neighbor. He looks like him, and I can’t understand a word he says. But this time I’m being careful not to agree to anything.
espn.com has a good article about Josh McCown and ‘brain training’. (It’s a good article, I only wish it was a little more specific.)
If you’re interested in understanding the Cats library, I’m a big fan of the book, Scala with Cats (formerly known as Advanced Scala with Cats). Noel Welsh and Dave Gurnell have a simple writing style, with good examples. Being an older person, I only wish a print version was available.

If you like computer history, cake.co has an interesting article by Chris MacAskill titled, The secret call to Andy Grove that may have helped Apple buy NeXT.
At the time of this writing there aren’t many examples of the Scala Exception
object allCatch
method to be found, so I thought I’d share some examples here.
In each example I first show the "success" case, and then show the "failure" case. Other than that, I won’t explain these, but hopefully seeing them in the REPL will be enough to get you pointed in the right direction:
If you’ve never heard of the term DICEE, it was coined by Guy Kawasaki. Mr. Kawasaki was a developer evangelist for the original Macintosh team in the 1980s, and used the term in at least one subsequent book to refer to great products.
“DICEE” is an acronym that stands for Deep, Indulgent, Complete, Elegant, and Emotive:
This slide on “Mast cell-associated disease-specific pain syndromes” comes from doctors Tania Dempsey and Lawrence Afrin. I don’t remember exactly where I saw it, but it was probably on The Mastocytosis Society Facebook page.

It looks like most of the talks from the recent Scala Days conferences are now online.
Have you ever felt like you were having someone else’s dream? This morning (July 24, 2017) I was having a “back to school (college)” dream, and thought, okay, whatever, I’m bored, I’ll go with it.
The short story is that when I woke up I remembered that one of the teachers was named Don Monk. I figured that was a name made up by my brain, but I googled it just now and found two college professors with that name, one at Rutgers, and the other just down the road at the University of Colorado, Boulder.
Bloomberg has a nice article about business strategy titled, Best Buy Should Be Dead, But It’s Thriving in the Age of Amazon.
My red pencil is one of my favorite possessions. When I get it out it means that I’ve just edited a print version of something and now it’s time to type up the corrections. It also means that I’m getting close to releasing a final version of whatever book I’m working on, which is also a good thing.

Last night I watched an episode of Father Brown where Mrs. McCarthy was judgmental about something her god-daughter did. (She was the girl’s godmother.) In my mind I thought, “Wow, she sure is judgmental and intrusive in the girl’s life.”
Then this morning I woke up and saw some photos on Facebook involving one of my young relatives that made my skin crawl. When I saw the photos I realized I didn’t know them at all, and I hated what they were doing. I wanted to grab them by the ear and yank them out of those pictures.
So it turns out that giving unconditional love is really hard when you see people you care about doing things that you think are really stupid.
I saw these Talk Nerdy To Me socks in a store window recently. For more information, it looks like they have them here on Amazon.

When you go to Alaska to get away from the heat and then need a break from eating fresh seafood all the time, ADN.com lists a few places where you can find a good burger in Anchorage.
I always find it confusing when people claim that the IO monad somehow makes an impure function pure. Frankly, I think that argument does a confusing disservice to people who are trying to learn functional programming (FP).
I’m a big fan of the book, Functional and Reactive Domain Modeling, and these are some of my notes (“CliffsNotes”) from the book, most of them coming from the first chapter.
Chapter 1. Functional domain modeling
- domain model
- the representation of how the business works
- blueprint of the relationships between the entities
- objects that belong to the domain
- behaviors those objects have
- the language/vocabulary of the business
- the context within which the model operates
- essential complexities - complexities inherent to the business
- incidental complexities - complexities introduced by the solution itself
Domain-driven design
- bounded context - smaller model within the whole; a complete area of functionality within the larger system
- the complete domain model is made up from a collection of bounded contexts
- bounded contexts communicate via services/interfaces/APIs (me: think of them as web services)
- ubiquitous language = domain vocabulary
Entities and value objects:
- entities have an
id
(like a database id), and they are mutable; usually has a definite lifecycle - value objects (like an address) don’t have an id; they are identified by the values that are contained, and are therefore immutable
- entity has an id that can’t change, and value object has a value that can’t change
Services:
- services = behaviors = functions
- usually models a use case of the business
Object lifecycles:
- creation
- participation in behaviors
- persistence to a data store
- factories (p.9)
- centralize code to create entities
- aggregates - a transaction boundary in the model
- aggregate root - guardian of the graph and single point of interaction of the aggregate with its clients
- Effective Aggregate Design by Vaughn Vernon
Scala:
- Use case classes to model aggregates (ADTs)
- Traits let you define modules which can be composed using mixin composition
Repositories:
- the interface (trait) has no knowledge of the underlying data store
Thinking functionally
- functions are the main abstraction to model domain behaviors (standalone functions in modules (traits), like Haskell)
- mutable state is an anti-pattern when it comes to reasoning about your code
- pure functions ...
- general principles:
- model immutable state as ADTs with case classes
- model behaviors as functions in modules
- behaviors in modules operate on their corresponding ADTs
- more:
- ADTs have no behaviors
- services are defined in modules, which are implemented as Scala traits
- when you need a concrete instance of a trait, create it with the
object
keyword
1.3.2 Pure functions compose (p.22)
- good examples
- composition = Unix pipeline (me)
- HOFs like
map
are known as combinators andThen
andcompose
examples- takeaway: “appreciate how function composition through combinators can lead to enrichment of domain behaviors”
1.4 Managing side effects
- stuff like I/O
- decouple side effects as far as possible from pure domain logic
1.5 Virtues of pure model elements
- equational reasoning
- substitution model of evaluation
- substitution model only works if functions are pure
- referentially transparent expressions
- three pillars of functional programming
- referentially transparency
- substitution model
- equational reasoning
Other good quotes/notes
“Abstractions compose when types align; otherwise you’re left with islands of artifacts you can’t reuse and compose.”
About monads and effects in functional programming:
- Future models latency as an effect
- Try abstracts the effect of failures (manages exceptions as effects)
- Option models the effect of optionality
Functional and Reactive Domain Modeling
If you haven’t read it yet, I highly recommend the book Functional and Reactive Domain Modeling, with one caveat: it tends to assume that you already know a lot about functional programming. For example, if you already know what functors and monads are, it can help you understand how to use them in Scala. If you don’t already know what those things are, I’ll point you to my own book, Functional Programming, Simplified, about 40% of which you can read for free.
This “Can someone explain to me the benefits of IO?” Reddit post makes for some interesting functional programming and referential transparency reading.