This is part 2 of a series of articles, “toString considered harmful”. [Part 1] introduced the problem in the context of a common design flaw present in object-oriented languages, and proposed a simple workaround.
In part 2, we look at advanced ways to organize “stringable” data, using either an object-oriented or functional style. Examples are in Scala because it equally supports either style.
It is easy to rant about the problems or unexpected subtleties involving the use of strings in programming languages. This post, however, is not so much a rant about strings as about design and meaning, with toString only as an obvious example.
I’ll describe a pitfall that came up in my code, and a solution, and make observations about how different programming languages address or avoid this problem.
Dec 5, 2013 · 1 minute read · Comments ScalaPlayWebPittsburghM*Modal
The Pittsburgh Scala Meetup met again with Josh walking through his code for an interactive Web tic-tac-toe program implemented with Play.
It was a good session. I’m finding that studying code (with the code’s author present) is a great way to learn, to discuss design decisions and alternate possible choices that could have been made. For example, when it comes to actors, there are decisions to be made about how many actors, what state they should contain, and how to transition.
Read On →
This is a review of the specific course numbered M101J, “MongoDB for Java Developers”, but it should apply to all thee introductory developer courses on MongoDB in any language, because actually, I had originally signed up months earlier for their original course (in JavaScript), and the content is largely the same (I had gotten busy and dropped that course).
This August meeting of OpenHack Pittsburgh was held at ModCloth, which I had never been to. It’s in Crafton, which is a place I’ve never been before, nearly half an hour drive from Pittsburgh. Because of worries about driving there near rush hour after work, I probably would not have signed up to attend had it not been for Justin, the organizer of OpenHack Pittsburgh.
What happened was that he asked for feedback about who was planning to work on what, and said he planned to learn some Elixir, a fairly new programming language built on top of the Erlang runtime. Since this language had been on my list of things to look into, I decided that learning loves company, so I proposed to learn some Elixir in a test-driven way!