zaph0d's comments

zaph0d | 13 years ago | 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 | 13 years ago | 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 | 13 years ago | 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 | 13 years ago | 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 | 14 years ago | 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 | 14 years ago | on: Roadmap – nginx

I am more excited about ETags support than SPDY & Websockets. Etags (when used correctly) are extremely handy.

zaph0d | 14 years ago | on: The Cleartrip Hurry Algorithm

It basically shows the number of seats left in the same fare-basis. The problem is with the communication, and not the supposed "algorithm".

zaph0d | 14 years ago | on: Big Data: principles and best practices (new book)

That's not true (at least not any more). You now get an account on Manning the first time you buy a book and you can download the electronic versions of those books any time from your account.

Screenshot of my account page - http://imgur.com/Hu7qT

The URL is - http://beta.manning.com

To clarify, the time limit applies only to the links that are sent via email to you. The latest version of the MEAP and the published versions are always available for download.

zaph0d | 14 years ago

Deleting on request from the author.
page 2