Monday, November 3, 2014

October 2014 1HaskellADay Problems and Solutions

October, 2014
  • October 1st, 2014, Wednesday: Pathways into Darkness Because Daerkness is the new Pink. Today's #haskell problem. ...AAAAAND we went there: Dark, Darkest, Darko! A solution to the #haskell grid-pathing problem using Data.Graph. FUN!
  • October 2nd, 2014, Thursday: Tweet, tweet! Summer Factorial! a #haskell 'sum'mer exercise for the Fall. From "Power set, HO!" to "Power Sets? NO!" A solution to today's longest factors-sum #haskell problem.
  • October 3rd, 2014, Friday: In which I get WHACKED by the Missus for today's #haskell problem (I've printed out the word-ladders in long form so you can give them to your Missus, thus to avoid enWHACKification! GROSS ('Get Rid Of Stupid wordS') club and goal-directed searches using Levenstein distances give us today's solution
  • BONUS! puzzles for today: YOU get RICK ROLLED! Oh, yeah! I went there!

  • You can't kill the metal, unless you're Rick Rolled; solution to #haskell bonus problem at

  • October 4th, 2014: Dear Dad, SEND + MORE = MONEY Today's #haskell problem. Problem SOLVED! (naively) ... for a small processing fee, ... ;)
  • October 7th, 2014: An American Family Today's #haskell problem gives us the #Twilight lexicon... in a 'VERY' 'BRIEF' synopsis. #ontology 8 of 21 questions are answered against the #Twilight (extended) family tree  My enthusiasm overcame my reasonableness.
  • BONUS #haskell problem for today! Renesmee's (doting) Aunts because EVERYONE dotes on Renesmee. By law. Do-it-to-it! "And Bella Swan lived Happily Ever After" ... and that's the whole point of the 4-book #twilight series. #ontology
  • October 8th, 2014: "A more clever approach than brute force is desirable" for today's #haskell problem (Me? Brute Force, All the WAY!) (Not so) Brutish pathing through triangular sums ... Commited Choice FTW! A solution to today's #haskell problem.
  • October 9th, 2014: Sugar and spice and everything nice ( that's what today's #haskell problem from a logic puzzle from 1957 is made of. A long path to a solution to this day's engagement announcements #haskell problem, involving monoidal Frege logic.
  • October 10th, 2014: "Oh, it's 4:42. No, it isn't, ... zzzz" Those kinds of conversations come up all the time in today's #haskell problem And the poor little matchstick boy went back to sleep in his warm, comfy bed, hot chocolate by his bedside a solution
  • BONUS! Okay, so you're saying liars ALWAYS lie and TruthTellers ALWAYS tell the truth. Wait ... even in Vegas? #Bonus In which we may learn about your sense of humo(u)r a solution using logic, meta-logic, and coercive logic. #ontology 
  • October 13th, 2014: In which we discover Columbus is Big in Japan ... no, wait: that's #ekmett. Today's #haskell problem. We solve this problem by WAY overusing the State Monad! ... Letter to a Young Haskell Enthusiast should have added: "Don't overused the State Monad!" I hear and obey the advice of ekmett!

  • What time is it? π-time? No. (But you were close ...) It's BONUS #haskell problem time! Go discover the New World! And, we discover, solving this bonus problem, that the New World was India (and not the ink), no matter what anyone else says, eh, Columbus?
  • October 14th, 2014: We look at reciprocally-cycled decimal values of fractions in today's #haskell problem In which we discover that @geophf must read the problem statement carefully. A solution to today's #haskell problem
  • October 15th, 2014: Today's #haskell problem: grid placement Or as Neo says: "Whoa."

  • October 16th, 2014: An ... 'intelligence' test for today's #haskell problem. Intelligence test: answered. I had to melt my brain to answer it, however, so that happened.
  • October 17th, 2014: Friedman day was yesterday, but it's today's #haskell problem. Bonus: Friedman proofsno less! ... using Frege's logic ... but only if you want to ... The solution (including the bonus solution) for the Friedman-day problem posted at  WITH FOR-LOOPS!
  • October 20th, 2014: O! Little Town of Milford! has a butcher, baker, and candlestick maker, but who is who? Today's #haskell problem. Okay, gag me with the sequence operator! BLEH! (I really should have gone relational calculus here! :/) A solution at
  • October 21st, 2014: Se7en Little numbers ... okay, well, four of them, anyway, for today's #haskell problem Quantum nodes of scintillating thought  A solution to today's #Haskell problem.

  • October 22nd, 2014: Word Numb3rs is today's #haskell puzzle (thanks to @BenVitale) 'AND' in your language of choice as you so choose. Hinglish-Vinglish is our response to this exercise. "Fruitful." Yeah. Well, at least we got Data.Numeral.English out of it. SWEET!
  • October 23rd, 2014: Today's #haskell problem comes from and is about ... well: Euler, himself! Well, if you wanted list of writer monads, you could've just asked for a list of writer monads 
  • October 24th, 2014: Even odds is our #haskell problem today, thanks to @BenVitale A solution (actually two defined solutions) to @BenVitale even odds problem posted for today's #haskell problem
I dub this coming week 'Kakuro week' for the theme of #haskell 
problems to solve (puzzle rendered using #haskell)

  • October 27th, 2014: #kakuro-week: the empty slate is our step one for our #haskell problem(s) to solve today

  • Then we have the...'filled'-slate as a solution to 'today's #haskell problems for #kakuro-week 
  • October 28th, 2014: «On y va!» declaims Sgt. Johnson as he charges headlong into solving today's #haskell problem 
  • And that's how a 'partial' cookie crumbles. Partially. A partial solution to yesterday's #haskell #kakuro problem
  • October 29th, 2014: A magnificent clue for today's #haskell problem in this #kakuro-puzzle-themed week
  • October 30th, 2014: So, what does the 'Su' mean? Today's #haskell puzzler is a sudoku-solver. That you wrote. DoIt-ToIt!
  • October 31st, 2014: Merry Christmas! No. Heurieusement anniversaire! Nope. TRICK OR TREAT! Ya, that's the stuff! Today's #haskell problem

Wednesday, October 1, 2014

September 2014 1HaskellADay problems and solutions

September, 2014

  • September 1st, 2014: They tried to kill the Metal...I don't know where I'm going with that. But rock-n-roll with today's #haskell exercise
  • September 2nd, 2014: Good morning! Triangle Sums is our #haskell problem for today: No triangles were harmed in the solution of their sum (nor in the summation of their solution)

  • September 3rd, 2014: Pay It Forward. What? You didn't think I'd just say: today's #haskell problem is hard and leave it at that, did you? Paid. Or: a constructivist approach reduces the generated sets from 200M+ down to 8 possible solutions That's doable. ... and here is the 'Mr. Clean' version of the solution: fast, and neat. Groovy!
  • September 4th, 2014: Today's #haskell problem: Abacus words because MRFE says "I don't like your math problems; I want more word problems"
  • September 5th, 2014: These 'edgy' relationships these days!  Remember when today's #haskell problem didn't involve graph theory? Data.Graph FTW! A solution to today's 4sum #haskell problem, and it didn't require generating 1625702400 solutions!
  • September 8th, 2014: We have puzzles 1 and 5 from the "Montley Stew" problem set for today's #haskell problem The solution-style to Montley Stew isswimming in list-compression stew
  • September 9th, 2014: King Tut! Our #haskell problem for today is NOT a Pyramid Scheme. Maybe.
  • September 10th, 2014: 'Sed' is 'but(t)' just another word ... in "'laddin" Today's #haskell problem is mix-n-match words. "But(t) I sed ..." ARG! Enough with the 3rd-grade humor! On with the solution to the mix-n-match words!
  • September 11th, 2014: A-plus for you when you solve today's #haskell exercise But an F- (NOT an F# ... geddit?) for /usr/share/dict/words :/ A solution to today's injectInto #haskell problem
  • September 12th, 2014: Today's #Haskell problem comes from She. She who commands you solve it before coding it. So, you know: there it is. Okay, 'thurt' is a word in WHICH Universe? A solution to today's #haskell 'ditto' problem
  • September 15th, 2014: "The name of the game is Connect Four!" and today's #haskell problem as suggested by a tweet from @DrEugeniaCheng. I played Connect 4 against myself and lost! :/ A semi-solution to today's #haskell problem at

  • September 16th, 2014: There's more than one way to slice and dice a matrix for today's #haskell problem (follow-up to yesterday's Connect4) A Hack-n-slash solution to today's diagonal view of matrices. Thebonus solution is provided back at the Connect Four answer to make that game complete:
  • September 17th, 2014: Do you Yahoo!? Today's #haskell problem: connecting to Yahoo!'s financial webservice I like my java GREEN! (java means 'coffee') A solution to stock webservice #haskell problem.

  • September 18th, 2014: Star (Tuna?) Fish? A radial word-finding/matching game is today's #haskell puzzle. Wait. Quantum...WHAT? A solution to today's #haskell problem using quantum superpositions to solve it. I'm not joking. STAR POWER! A solution for pretty-printing the star-puzzle
  • September 19th, 2014: Continued fractions and dual inversionals are today's #haskell problem It even comes with (thoughts about) flowers. #Ult Today's problem was inspired by a comment, then the main article, from @aperiodical That was some LOOOOOOOONG Division! A solution to today's #haskell problem.
  • September 22nd, 2014: Oh, noes! The 'M'-word! for today's #haskell exercise. Project Eulerproblem 11'M' is for 'Monoid' A solution to today's #haskell problem.
  • September 23rd, 2014: "Oh, the snark bites, with his teeth, dear." MACD Knife ... geddit? Today's #haskell problem is a technical indicator.
  • September 24th, 2014: Jones, Smith, and Brown work at the Bank... but not Mr. Banks.A logic puzzle from 1957 for today's #haskell puzzle A pair of PhDs ( helped to solve today's #haskell problem. Neatly, too, I might add.
  • September 25th, 2014: Corned-beef hashi? No, that's not right, and now I'm hungry! :( Shoot! Well, anyway: today's #haskell problem.
  • September 26th, 2014: HA! I TOLD you we'd be getting to cipher-text! From the 1700's, still: it IS cipher text for today's #haskell problem. Ooh! The Plot Thickens (like pea soup)! "ALLMENHAVING" and "be mis T r U st ed " is a solution to today's problem.
  • September 29th, 2014: Big (Crypto) Generator! Today's #haskell problem is a follow-on to Friday's. Human Error ... WHAT human error? A solution to today's make-your-own-cypto-table #haskell problem
  • September 30th, 2014: "I wanna be a blue-collar man!" Yes, but who, and which occupation? Today's #haskell problem addresses this. Plumber, ... or painter? IDK! TWO-solutions to today's #haskell problem (one of them MAY be correct... :/ )

Monday, September 1, 2014

August Haskell Daily puzzles and solutions

August, 2014

  • August 1st, 2014: "But programming isn't math, so ..." Today's #haskell problem? 'Fix' yesterday's solution to be less ... 'icky.' π, fast (So you're not eating π? ... okay: 'quickly.') A solution set to today's exercises with Wow-o-wow results.
  • Bonus: August 1st, 2014: This is Embarrassing(ly parallel) to have π in da face!
  • A-to-the-ST for da D-down-low-on-the-SL. Today's #haskell exercise is write your own language, then some rules. Yeah. LAWLZ! NAND on the A-to-the-ST! A solution to the first 2 exercises to today's problem. YMMV: not pretty nor generic.
  • Baby needs a new pair of shoes! And you need a new daily #haskell problem to solve. Done! ;) Love is the Universal Language. No, wait. We were talking about Money, yes? Me confused. Solution to today's exercise I have a Yen for Thinking Japanese, or so I think so ... a solution to the bonus #haskell exercise
  • Bayes was a man of letters. A Bayesian classifier for letter-recognition? Sure, let's give it a go for today's #haskell exercise. So now we know 'M' looks like 'W' to some peeps but 'B', 'I', 'O' check out fine, so WE ARE READING WITH HASKELL! YAY ... added definitions to do test runs over the entire data set and then did various runs, tweaking the system. Results noted. Informative.
  • Today's #haskell exercise. An expert system for blood donation. I use the term 'expert' loosely, eh? ;) Have at it! "I vant to drinq yur bloot! Bwa-hahaha!" Okay. That quote is just ... creepy. A solution to today's exercise is at
  • Veni, Vidi, ... Duci? Today's #haskell exercise. It is a relief to know that no tactical nukes were launched by testing the solution to today's #haskell exercise. or How do you count Mississippi's in Roman numerals?
  • August 11th, 2014, Monday: You've heard of 'Rock Management'? How about ROCK LOBSTERS! GIVE ME A ROCK, NAOW!!!1!!!!11! Today's #haskell exercise 
  • August 12th, 2014, Tuesday: To Fract or Not to Fract: why are we even considering this question? Today's #haskell exercise 

  • Ooh! Bonus problem? On a Tuesday? Wowsers! Today's #haskell #bonus problem: "Continuum spectrum maximum... uh, 'thing'um"
  • August 13th, 2014, Wednesday. No problem! (literally), but: "Fract! The Cylons!" No... wait: Starbuck used a different word. A solution to yesterday's fracting problem is at
Flatliners. No fracting, no 'peak'ing, just a baseline data set of 
initializeSpectrum defined with flatline function.

Twin Peaks. Still not fracted, but data set with two spikes 
rolled into the base data set with smoothSpike fn 

Fracted. Data set with peaks, fracted using the frackedSpike function

  • August 14th, 2014, Thursday: Pining for that next fibo date-time before 2584. Today's #haskell problem inspired by @AlgebraFact Updated problem. Tightened up return value, removing unnecessary semideterminism. So, it gives, leik, a septatuple answer, leik. ... Yeah. Time keeps flowing like a (Fibonacci) river, to the sea. A solution to  the 'next Fibonacci' problem posted today.
  • Hail, Eris! or the Law of Fives or today's #haskell problem (implementing a Ripple-down rule set). Do it to it! One of three-parter solution to today's problem: Forall Existential(ism) A solution allowing forall-quantified values. Two of the three-part solution: All you need is fnord (la-di-da-di-dah)! Rippling down (and accumulating fired) rules Third of three-part solution: RippleDownRuleto ergo sum, adding rules to the RDR system  Updated the 3rd solution to the RDR (Writer monad definition) to ripple down to left and right, fixing inconsistency in rule findings.
  • August 18th, 2014: What's FP good for? Crypto and technical (financial) indicators. Why? Um, let's do today's #haskell exercise! Full on, all the way! Double Rain-... wait: line-graph. Solution to today's #haskell exercise

  • August 19th, 2014: What does it all mean? All the way! No, wait: this is just today's #haskell exercise (backtesting SMA indicator ). Take the monoid and run(State-WriterT), or WAAH! WAAH! I lost 100 corn chips on my investment strategy or, solution: But, as solace, it does come with a pretty picture, illustrating today's solution. Ooh! 

  • August 20th, 2014: Next up for today's #haskell exercise is the Exponential Moving Average. A solution to the E(xponential)M(oving)A(verage) #haskell problem: Stately Conformance 

  • August 21st, 2014: My Jeans. No ... I meant: 'GENES'! That's it. Today's #haskell exercise. A solution to (not even CLOSE to) 'yesterday's' #haskell exercise: Nature or Nurture? We present a genetic algorithm
  • August 22nd, 2014: Today's (much delayed) #haskell problem: the Silver Ratio (from @AlgebraFact Every cloud has a silver lining .. Every Haskell problem has a solution. (sometimes) (except noncomputable problems)

  • August 25th, 2014: LYADCFGG! Today's #haskell exercise? (automated/learned) Document classification.
  • August 26th, 2014: "Join me, Luke, on the Dark Side of the Force, and help me go #FORTH to solve today's #haskell exercise! MWA-HAHA!" The World's smallest DSL: Forth. A solution to today's #haskell exercise
  • August 28th, 2014: "As I compose this #haskell problem ... p.s. I love you ... You! You! You!" #1960s #song A little card logic problem. Oh, NOES! LOOK OUT! IT'S A CARD-#SHARKNADO! Nah, it's just 'today's #haskell solution, is all
  • August 29th, 2014: Groovitudes! WordNet Themes! or: today's #haskell exercise A 3x3 matrix has 36 possible solutions. A 5x5 matrix? Over 200M poss solutions? YIKES! A solution to the themed-words
  • The Forth language problem solution given on August 26th gives a very snazzy RPN ('reverse Polish notation') calculator, but that's all it does the ':'-defining word needs access and look-ahead to the program parsed stream, and that's a bit more to ask than pushing and popping stack operators.
  • For the August 29th problem(WordNet themes) the raw generated solution set is over 209M possibilities. My little Haskell program was not finished scanning them over four hours when I killed the process. However, my dear wife solved the problem in under five minutes. Setting aside the fact that she's a genius, the program needs to be better. It needs to use the ontology of English-language words to eliminate fruitless endeavors during their generation, not afterwards during the test phase.

Monday, August 25, 2014

Dylan: the harsh realities of the market

So, this is a little case study.

I did everything for Dylan. And when I say everything, I mean everything.  Here's my resumé:

  • I got excited about Dylan as a user, and I used it. I bought an old Mac that I don't ever remember the designation for, it's so '90's old, and got the floppies for the Dylan IDE from Apple research.
I'm not joking.

  • I integrated Dylan into my work at work, building an XML parser then open-sourcing it to the community under the (then) non-restrictive license. I think mine was the only XML parser that was industrial-strength for Dylan. Can't claim originality: I ported over the Common-LISP one, but it was a lot of (fun) work.
  • I made improvements to the gwydion-dylan compiler, including some library documentation (you can see my name right there, right in the compiler code), including some library functionality, did I work on the compiler itself? The Dylan syntax extensions or type system? I don't recall; if not in those places, I know I've looked at those guts: I had my fingers all over parts of the compiler.
I was in the Dylan compiler code. For you ll-types ('little language') that's no big deal.

But ask a software developer in industry if they've ever been in their compiler code. I have, too: I've found bugs in Java Sun-compiler that I fixed locally and reported up the chain.
  • I taught a course at our community college on Dylan. I had five students from our company that made satellite mission software.
  • I effing had commercial licenses bought when the boss asked me: what do we have to do to get this (my system) done/integrated into the build. I put my job on the line, for Dylan. ... The boss bought the licenses: he'd rather spend the $x than spending six weeks to back-port down to Java or C++.
  • I built a rule-based man-power scheduling system that had previously took three administrative assistants three days each quarter to generate. My system did it, and printed out a PDF in less than one second. I sold it, so that means I started a commercial company and sold my software.
I sold commercial Dylan software. That I wrote. Myself. And sold. Because people bought it. Because it was that good.

Hells yeah.

Question: what more could I have done?

I kept Dylan alive for awhile. In industry. For real.

So why is Dylan dead?

That's not the question.

Or, that question is answered over and over and over again.

Good languages, beautiful languages, right-thing languages languish and die all the time.

Dylan was the right-thing, and they (Apple) killed it in the lab, and for a reason.

Who is Dylan for?

That's not the question either. Because you get vague, general, useless answers.

The question is to ask it like Paul Graham answered it for LISP.

Lisp is a pointless, useless, weird language that nobody uses.

But Paul and his partner didn't care. They didn't give a ...


... what anybody else thought. They knew that this language, the language they loved, was built and designed and made for them. Just them and only them, because the only other people who were using it were college kids on comp.lang.lisp asking for the answers for problem-set 3 on last night's homework.

That's what Lisp was good for: nothing.
That's who Lisp was good for: nobody.

Same exact scenario for Erlang. Exactly the same. Erlang was only good for Joe Armstrong and a couple of buddies/weirdos like him, you know: kooks, who believed that Erlang was the right-thing for what they were doing, because they were on a mission, see, and nothing nobody could say could stop them nor stand against them, and all who would rise up against them would fall.


What made Lisp and Haskell and Erlang and Scala and Prolog (yes, Prolog, although you'll never hear that success story publicly, but $26M and three lives saved? Because of a Prolog system I wrote? And that's just one day in one month's report for data? I call that a success) work when nobody sane would say that these things would work?

Well, it took a few crazy ones to say, no, not: 'say' that it would work, but would make it work with their beloved programming language come hell or high water or, worse: indifferent silence, or ridicule, or pity from the rest of the world.

That is the lesson of perl and python and all these other languages. They're not good for anything. They suck. And they suck in libraries and syntax and semantics and weirdness-factor and everything.

But two, not one, but at least two people loved that language enough to risk everything, and ...

They lost.

Wait. What?

Did you think I was going to paint the rosy picture and lie to you and say 'they won'?

Because they didn't.

Who uses Lisp commercially? Or Haskell, except some fringers, or Scala or Clojure or Erlang or Smalltalk or Prolog

... or Dylan.

These languages are defined, right there in the dictionary.

Erlang: see 'career wrecker.'

Nobody uses those languages nor admits to even touching them with a 10-foot (3-meter) pole. I had an intern from college. 'Yeah, we studied this weird language called ML in Comp.sci. Nobody uses it.'

She was blown away when I started singing ML's praises and what it can do.

A meta-language, and she called it useless? Seriously?

Because that's what the mainstream sees.

Newsflash. I'm sorry. Dylan, Haskell, Idris: these aren't main-stream, and they never will be.

Algebraic types? Dependent types? You'll never see them. They're too ... research-y. They stink of academe, which is: they stink of uselessness-to-industry. You'll be dead and buried to see them in this form, even after they discover the eternity elixir. Sorry.

Or you'll see them in Visual Basic as a new Type-class form that only a few Microserfs use because they happened to have written those extensions. Everybody else?


Here's how Dylan will succeed, right now.

Bruce and I will put our heads together, start a company, and we'll code something. Not for anybody else to use and to love and to cherish, just for us, only for us, and it will blow out the effing doors, and we'll be bought out for $40M because our real worth is $127M.

And the first thing that Apple will do, after they bought us, is to show us the door, then convert the code into Java. Or Swift. Or Objective-C, or whatever.

And that's how we'll win.

Not the $40M. Not the lecture series on 'How to Make Functional Programming Work in Industry for Real' afterwards at FLoC and ICFP conferences with fan-bois and -girls wanting to talk to us afterwards and ask us how they can get a job doing functional programming.

Not that.

We'll win because we made something in Dylan, and it was real, and it worked, and it actually did something for enough people that we can now go to our graves knowing that we did something once with our lives (and we can do it again and again, too: there's no upper limit on the successes you're allowed to have, people) that meant something to some bodies. And we did that. With Dylan.


I've done that several times already, by my counting: the Prolog project, the Dylan project, the Mercury project, and my writing.

I'm ready to do that, again.

Because, actually, fundamentally, doing something in this world and for it ... there's nothing like it.

You write that research paper, and I come up to you, waving it in your face, demanding you implement your research because I need it to do my job in Industry?

I've done that to three professors so far. Effing changed their world-view in that moment. "What?" they said, to a person, "somebody actually wants to use this?" The look of bemused surprise on their faces?

It was sad, actually, because they did write something that somebody out there (moiself) needed, but they never knew that what they were doing meant something.

And it did.

Effing change your world-view. Your job? Your research? Your programming language?

That's status quo, and that's good and necessary and dulce and de leche (or decorum, I forget which).

But get up out of the level you're at, and do something with it so that that other person, slouched in their chair, sits up and takes notice, and a light comes over their face and they say, 'Ooh! That does that? Wow!' and watch their world change, because of you and what you've done.

Dylan is for nothing and for nobody.

So is everything under the Sun, my friend.

Put your hand to the plow, and with the sweat of your brow, make it yours for this specific thing.

Regardless of the long hours, long months of unrewarded work, and regardless of the hecklers, naysayers, and concerned friends and parents, and regardless of the mountain of unpaid bills.

You make it work, and you don't stop until it does.

That's how I've won.

Every time.

Friday, August 1, 2014

1HaskellADay July 2014 problems and solutions

  • July 1st, 2014: (text:) "Hi, all! @1HaskellADay problems are back! #YAY First (renewed) problem: a verbose way of saying, 'Give me a deque!'" Deque, last, and all that (verbose version with hints) (solution: Deque the halls (with my solution): Data.Deque)
  • July 2nd, 2014: (text:) "Today's Haskell exercise: Vectors, length in constant time, and (bonus) reverse return in constant time." Vector (solution: Vector: Magnitude, and Direction, OH, YEAH! Data.Vector)
  • July 4th, 2014: (text:) "Today's exercise(s). pack/unpack. encode/decode. Cheer up, sweet B'Genes!" Cheer up, Sweet B'Genes (solution: GATTACA)
  • July 7th, 2014: (text:) "#haskell daily exercise: ROLL with it, Baby!  ('cause I'm feeling a little #forth'y')" Roll (solution: Rollin' on the (finite) river)
  • Bonus problem: July 7th, 2014: (text:) "For those who found the 'roll'-exercise trivial; here's (a more than) a bit more of a challenge for you to play with." Acid rules! (solution: "A solution set to today's challenge exercise: BASIC ...  ... and Acidic  ... WHEW! That was fun!" BASIC ... and Acitic)
  • July 8th, 2014: (text:) "Today's #Haskell exercise: LOTTO! Powerball! Mega-whatever! Who's the big winner?" Lotto (solution: "And the big winner today is ... solution-set to today's #Haskell lotto exercise" ... and the winner is ...)
  • Bonus problem: July 8th, 2014: (text:) "#bonus #haskell exercise: Well, that was RND... Randomness, and such (or 'as such')" Well, that was RND (solution: For YESTERDAY's bonus question of roll-your-own-rnd-nbr-generator, here's one as comonadic cellular automata (*WHEW*) Data.Random)
  • July 9th, 2014: (text:) "Okay, ... WHERE did yesterday and today GO? :/ #haskell exercise today: "Hey, Buddy!"  I will post solution in 4 hours" Hey, Buddy! Distinct sets-of-an-original-set. (solution: "Here's a story ..." A(n inefficient) solution to bunches and cliques." Brady Bunch)
  • July 10th, 2014: (text:) "Today's #haskell list-exercise: "Get out of the pool!"  Will post a solution at 9 pm EDT (which is what time CET? ;)" (solution: "She's a supa-freak! She's supa-freaky! (Bass riff) A solution to today's #haskell exercise about list-length-ordering")
  • July 11th, 2014: (text:) ""It's Friday, Friday!" So, does that mean Rebecca Black wants to code #haskell, too? Today is a Calendar #exercise" (solution: ""In a New York Minute": a solution to today's #haskell exercise that took WAAAY more than a minute to complete! #WHEW")
  • July 14th, 2014: (text:) "Today's #haskell exercise: isPrime with some numbers to test against. They aren't even really Mp-hard. ;)" First stab at primality-test (solution: "A simple, straightforward stab at the test for primality. #haskell #exercise" The start of a primal inquiry
  • July 15th, 2014: (text:) "Primes and ... 'not-primes.' For a prime, p, a run of p-consecutive 'plain' numbers is today's #haskell exercise:" (solution: "So ya gotta ask yerself da question: are ya feelin' lucky, punk? Run of p non-primes in linear time  #haskell exercise." Alternate solution by Gautier:
  • July 16th, 2014: (text:) "Difference lists? We no need no steenkin' Difference lists!"  DList in #haskell for today's exercise. (solution: "DLists? We got'cher DList right here! A solution to today's #haskell exercise is posted at")
  • July 17th, 2014 (text:) " Prélude à l'après-midi d'un Stream ... I thought that last word was ... something else...? #haskell exercise today." Comonads for lists and Id. (solution: "Control.Comonad: That was easy! #haskell exercise #solution" Learn you a Comonad for Greater GoodFunny story, bro'! id is not necessarily Id. (I knew that.) #haskell solution")
  • Bonus exercise: July 17th, 2014 (text:) "Streams are natural, streams are fun, streams are best when ... THEY'RE BONUS QUESTIONS! #bonus #haskell exercise" LET'S GET THIS PARTY STARTED! (solution: "Take this Stream and ... it! #solution to today's #haskell #bonus exercises")
  • July 18th, 2014: (text: "Today's #haskell exercise: Frère Mersenne would like a prime, please.") (see solution next bullet)
  • Bonus exercise: July 18th, 2014 (text: "#bonus prime-time! Frère Mersenne would be pleased with a partial proof of a prime ... in good time.") (solution: "A #haskell #solution for (monadic?) primes and the #bonus interruptible primes.") Primary primes.
  • Bonus-bonus exercise: July 18th, 2014 (text: "Ooh! π-charts! No. Wait. #bonus-bonus #haskell exercise.") (solution: "#bonus-bonus: a #solution")

  • July 21st, 2014: (text: "Demonstrating coprimality of two integers with examples #haskell exercise") (solution: "A coprimes solution #haskell problem is at")
  • July 22nd, 2014: (text: "The prime factors of a number (and grouping thereof) as today's #haskell exercise.") (solution: "OKAY, THEN! Some prime factors for ya, ... after much iteration (torquing) over this #haskell exercise solution.")
  • Bonus exercise: July 22nd, 2014: ("For today's #bonus #haskell exercise you'll find a Bag 'o gold at the end of the rainbow") (solution: "Second things first: a definition for the Bag data type as today's #bonus #haskell exercise.")
  • July 23rd, 2014: (text: "Today's #haskell exercise, two variations of Euler's totient function") (solution: "And, for a very small φ ...  is a solution-set to today's #haskell exercise.")
  • July 24th, 2014: (text: "WEAKSAUCE! Goldbach's conjecture irreverently presented as a #haskell exercise.") (solution: "That solution to today's #haskell exercise will cost you one Goldbach (*groan!*)")
  • July 25th, 2014: LOGIC! Peano series: it's as easy as p1, p2, p3 ... ... in today's #haskell exercise. "Excuse me, Miss, where do we put this Grande Peano?" A solution to today's #Haskell exercise in the HA!-DSL
  • Bonus: July 25th, 2014: Bonus #haskell problem for today. But not as easy as λa, λb, λc ... Church numerals and booleans. Correction: Ooh! forall! Church encodings and Haskell have a funny-kind of relationship. Updated the #bonus #haskell exercise with rank-types and forall. Solution: "Gimme that olde-time Church encoding ... it's good enough for me!" A solution to today's #bonus #haskell exercise
  • July 28th, 2014: George Boole, I presume? Today's #haskell exercise: Solution: This and-or That ... a NAND-implementation of today's #haskell exercise at
  • July 29th, 2014: Readin' 'Ritin' 'Rithmetic: today's #haskell exercise Solution: That's alotta NANDs! A solution to today's exercise at
  • July 30th, 2014: ACHTUNG! BlinkenLights! Today's #haskell exercise Solution: Let it Snow! Let it Snow! Let it (binary) Snow! A solution to today's exercise is at 
  • July 31st, 2014: π-time! Today's #haskell exercise. BLARG! UPDATE! Please read the update attached to the problem statement, simplifying the calculation quite a bit: Solution: Apple or coconut π? A solution to today's problem

Notes on the problems
  • July 9th, 2014. I didn't quite know how to go about this, so I made several attempts with the State pattern. But how to describe it? It's the base pool from which you draw, and each (sub-)choice-point affects it, what's that type? I spent way too much time trying to discern the type, and failing. But now, a much simpler approach suggests itself to me (after experiencing the New York Minute exercise): this is simply a permutation of the list, and then that permutation is partitioned by the sizes of the groups! Implementing permute-then-partition is a much simpler approach than tracking some monster monadic state transformer.

    No, that didn't work, either. A permutation will give you [[1,2], ...] and[[2,1], ...] That is, all solutions, even the redundant ones. So, I reworked the problem simply following the data. With takeout feeding the iterative-deepening function, I finally got a guarded state-like thingie working fast and correctly. The new solution is on the same page as the old one.
  • July 11th, 2014. The New York Minute problem demonstrates the implementation of a rule-based classifer. It takes unclassified numeric inputs, and based on the cues from the rules, either types each number into day, month, year, hour, minute, or rejects the input data as unclassifiable. I was pleased to have implemented this entire system in less than two days of work! Sweet!
  • July 22nd, 2014. So, I've been running up against the double-exponential cost of computing a stream of primes for some time now since I gave the solution to the question of demonstrating the Prime Number Theorem. So now I have to tackle of bringing down that extraordinary, or unreasonable, cost down to something useable, and along those lines (of feasibility), I'm thinking of instead of regenerating and re-searching the primesish stream that we have some kind of State-like thing of ([already generated primes], indexed-primesish) ... something like that. Solution: "General improvement of problem-solving modules in anticipation of solving today's #haskell exercise, including primes:"