Today, I had a Clojure quiz for myself. How to write a function that print out a number and return a function that will print out an incremented number and return out a function with the same behavior again and again, never end.
For those who are familiar with Clojure might find it easy but for me it took a while and I couldn't solve it so I decided to start solving it with Ruby first.
This is my solution.
After that it was way more easier to port it to Clojure.
Saturday, July 14, 2012
Thursday, July 5, 2012
I get paid for code that works, not for tests ... - Kent Beck
This quote by Kent Beck is just popping up all around articles I have read these days. Want to keep it here.
I get paid for code that works, not for tests, so my philosophy is to test as little as possible to reach a given level of confidence (I suspect this level of confidence is high compared to industry standards, but that could just be hubris). If I don't typically make a kind of mistake (like setting the wrong variables in a constructor), I don't test for itFrom http://stackoverflow.com/questions/153234/how-deep-are-your-unit-tests/153565#153565
Subscribe to:
Posts (Atom)
Collectd PostgreSQL Plugin
I couldn't find this link when searching with google https://www.collectd.org/documentation/manpages/collectd.conf.html#plugin-postgresq...
-
sudo su postgres supply your Mac password modify /Library/PostgreSQL/9.x/data/pg_hba.conf from local all all md5 to local all all ...
-
Put your cursor on the text box of the post/comment you want to indent Go to the menubar at the top of the screen Edit > Emoji & ...
-
I ran to this error the other day when I tried to export a dump file from a slave Postgres database. cpg_dump: Dumping the contents of ta...