HNHacker News
TopNewBestAskShowJobs

zaph0d

1,114 karma · joined November 26, 2008

Clojure hacker.

Co-founder & CTO at helpshift.com

b.ghose at helpshift.com

http://freegeek.in

submissionscomments
zaph0d··on Ram Dass has died
Maharajji's (Neem Karoli Baba) only possession was a blanket and he was living in a remote village in North India in the 60's. There is little chance that he had access to the drugs you mentioned.

And the LSD that was carried by Ram Dass was made by Sandoz, arguably the purest LSD that you could ever get.

May be reading Ram Dass' account of the event in _Be Here Now_ will provide some much needed context.

zaph0d··on Barliman – real-time program synthesis to make the programmer's life easier
Barliman is written in miniKanren[0], a logic/relational programming system built by Daniel Friedman[1], Will Byrd[2] & Oleg Kiselyov[3]. There are implementations of miniKanren in languages other than Scheme, one of the prominent being Clojure[4].

To oversimplify, in the miniKanren world programs are written using relational logic, wherein there are "variables" and then certain "relationships" between the variables. That is the program specification. Now we can run the specification and allow miniKanren to generate one or more variables that satisfy the relations. Thus a miniKanren program can have more than one answers. One interesting side-effect of this kind of an abstraction is that programs can also be run backwards to generate more programs that satisfy certain relations. That's pretty much what's happening with Barliman.

[0] http://minikanren.org/ [1] https://en.wikipedia.org/wiki/Daniel_P._Friedman [2] http://webyrd.net/ [3] http://okmij.org/ftp/ [4] https://github.com/clojure/core.logic

zaph0d··on The Land of Lisp
I started my career hacking Common Lisp (Allegro CL), these days I do Clojure, among other things.

That comic by Dr. Barski tears me up every time! Just to test, I went and read the comic again and I cried, again!

I have met Dr. Barski personally at a Clojure conference many years ago and I still remember him as an extremely kind and knowledgeable person.

Thank you for the Land of Lisp, Dr. Barski! Some day, we will be able to assemble our guilds and beat the Insectoids for good. Until then,long live language du jour!

zaph0d··on Ask HN: In Bay Area, starving, homeless and in search of work
Hello stolen_y, we might have the right kind of gig for you. We are based in SF city. Please send me an email as soon as you can. bg@helpshift. com
zaph0d··on Ask HN: Who's using Clojure in production?
Alex, there is also a small company called Helpshift that's using Clojure in production since 2009 :-)
zaph0d··on Who owns the fish? A Common Lisp solution to "Einstein's Riddle" (2004)
These kind of problems are more elegantly solved in logic (aka relational) programming languages like Prolog and similar logic programming implementations like miniKanren & Clojure's core.logic. Here's the same problem solved using Clojure's core.logic library https://github.com/swannodette/logic-tutorial/blob/master/sr...
zaph0d··on My website was stolen by a hacker and I got it back
namecheap.com is definitely one of the best per my experience and what I have heard.
zaph0d··on Does the next decade belong to Go?
The next decade could belong to Julia.
zaph0d··on The Future of JavaScript MVCs
Hi Jordan, ReactJS looks really awesome. Curious, what kind of persistent data-structures do you use at Facebook? Are they similar to the ones on Clojure[Script]?
zaph0d··on Linux-ng
Indeed it is an open security hole. See my other comment.
zaph0d··on Linux-ng
The repository was not created by Linus. It was a Github security exploit discovered by a friend of mine. Apparently he had contacted Github before exploiting but they didn't show any interest in fixing the issue. There should be a clarification from him soon.
zaph0d··on Libuv developer chided for making docs gender neutral
There was a sign-off apparently: https://github.com/joyent/libuv/commit/804d40ee14dc0f82c482d...
zaph0d··on Try Hy
Very nice. Surface syntax (and some semantics like interop) seem to be heavily inspired by Clojure :-)
zaph0d··on I'm learning to code by building 180 websites in 180 days. Today is day 115
Kudos to you Jennifer. I hope your path inspires many other aspiring programmers.
zaph0d··on Firefox Takes the Performance Crown From Chrome
Actually not; Firefox beat Chrome comprehensively in the overall test. Chrome actually came 3rd in the list - http://www.tomshardware.com/reviews/chrome-27-firefox-21-ope...
zaph0d··on Russian Proton Rocket crashes Seconds after Launch
ISRO's total budget for the year 2012-13 is ~$950 million. Apparently this project cost them ~$250 million all inclusive.
zaph0d··on Russian Proton Rocket crashes Seconds after Launch
Well, two launches within a day's time, both carrying navigation satellites.
zaph0d··on Russian Proton Rocket crashes Seconds after Launch
Compare with the ISRO launch on Monday that was a success - http://www.spaceflight101.com/pslv-c22-launch-updates-irnss-...
zaph0d··on Clojure core.async Channels
It's not dead yet. David Miller has been untiringly maintaing Clojure's CLR implementation for years now. Clojure CLR right now has feature parity with Clojure JVM. core.async is still alpha (it's also an external lib), I bet that once it reaches some stability David will add support for CLR in a weekend (as it has been usually). Unfortunately that doesn't mean there is much community interest in the CLR port though, but David's relentless stewardship of the project is relentless.

Example: https://groups.google.com/forum/#!topic/clojure/Kvefcae2W6s

Project Source: https://github.com/clojure/clojure-clr

zaph0d··on Chicken Chicken Chicken: Chicken Chicken [pdf]
"Buffalo buffalo Buffalo buffalo buffalo buffalo Buffalo buffalo" would have at least been grammatically correct.
zaph0d··on How I attacked a fellow student
I am guessing that the student in question was from India. That's how many Indians write official/business letters; likely a relic of the colonial times.
zaph0d··on Explorations in Clojure's core.logic
According to the author's update, it will cover core.logic - http://blog.fogus.me/2013/02/08/moar-joy/
zaph0d··on Calcutta girl who fled home & marriage at 17 returns as millionaire US innovator
Of course. His real name is Farokh Balsara.
zaph0d··on 28yr old self taught rocket engineer attempting land speed record
And he clearly is a very interesting man - http://newsimg.bbc.co.uk/media/images/47370000/jpg/_47370392...

Context: http://news.bbc.co.uk/2/hi/science/nature/8535938.stm

zaph0d··on Airtel, an Indian ISP, penalized for blocking a torrent site
The court judgement is ambiguous as hell. It doesn't mention either the website or the software that the plaintiff had tried to download.

This is how they explained the situation -

"The complainant has taken network service connection for his mobile since 5 years and subscribed for GPRS service. He tried to download an application from website using his phone GPRS service through torrent."

Bittorrent through GPRS? Mind boggling.

zaph0d··on A sudoku solver in 33 lines of Clojure
It took core.logic ~1100 msecs on my Macbook Air.

    (time (sudokufd
            [8 0 0 0 0 0 0 0 0
             0 0 3 6 0 0 0 0 0
             0 7 0 0 9 0 2 0 0
             0 5 0 0 0 7 0 0 0
             0 0 0 0 4 5 7 0 0
             0 0 0 1 0 0 0 3 0
             0 0 1 0 0 0 0 6 8
             0 0 8 5 0 0 0 1 0
             0 9 0 0 0 0 4 0 0]))

    ;; "Elapsed time: 1029.618 msecs"
    ((8 1 2 7 5 3 6 4 9
      9 4 3 6 8 2 1 7 5
      6 7 5 4 9 1 2 8 3
      1 5 4 2 3 7 8 9 6
      3 6 9 8 4 5 7 2 1
      2 8 7 1 6 9 5 3 4
      5 2 1 9 7 4 3 6 8
      4 3 8 5 2 6 9 1 7
      7 9 6 3 1 8 4 5 2))
zaph0d··on Why is Clojure so slow?
There is the :const metadata -

(def ^:const PI 3.14)

zaph0d··on The THX Sound
This is the THX sound synthesised using Overtone, a music synthesis program.

  (definst thx [gate 1]
  (let [target-pitches (map midi->hz [77 74 72 70 65 62 60 58 53 50 46 34 26 22 14 10])
        r-freq         (env-gen:kr (envelope [1 1 0.007 10] [8 4 2] [0 -4 1] 2) gate)
        amp-env        (env-gen:kr (envelope [0 0.07 0.21 0] [8 4 2] [0 1 1] 2) gate :action FREE)
        mk-noise       (fn [ug-osc]
                         (mix (map #(pan2 (ug-osc (+ (* r-freq (+ 230 (* 100 (lf-noise2:kr 1.3))))
                                                     (env-gen:kr (envelope [0 0 %] [8 6] [0 -3]))))
                                          (lf-noise2:kr 5))
                                   target-pitches)))
        saws           (mk-noise saw)
        sins           (mk-noise sin-osc)
        snd            (+ (* saws amp-env) (* sins amp-env))]
    (* 0.5 (g-verb snd 9 0.7 0))))
https://github.com/overtone/overtone/blob/master/examples/th... http://overtone.github.com/
zaph0d··on Ask HN: Clojure code worth reading?
Some of my favourites -

* Enlive, a HTML scraping & templating library implemented on top of DOM parsing & state machines https://github.com/cgrand/enlive

* Core Logic, a Prolog-like logic programming library https://github.com/clojure/core.logic

* The ClojureScript compiler, a Clojure compiler that targets JavaScript https://github.com/clojure/clojurescript/blob/master/src/clj...

* Ring, a Rack/WSGI like web-app library https://github.com/mmcgrana/ring

* Midje a very powerful test framework https://github.com/marick/Midje

* Carmine, a Redis client lib in Pure Clojure https://github.com/ptaoussanis/carmine/

[EDIT] Added Midje, Ring.

zaph0d··on Roadmap – nginx
Etags are useful for static assets as well.
Page 1 of 7Next →