HNHacker News
TopNewBestAskShowJobs

corruptio

34 karma · joined March 19, 2014

submissionscomments
corruptio··on WikiTok
I need it to loop subway surfers on the side. To keep my attention.
corruptio··on Show HN: Pipes puzzle (a.k.a. Net) on a hexagonal grid
Yup, it finds the play area and starts clicking. I haven' tried the wrapped version yet, but i think the nonwrap is funner. Also I wouldn't mind a 50x50 .....
corruptio··on Show HN: Pipes puzzle (a.k.a. Net) on a hexagonal grid
Whelp this just ate up a night's worth of sleep... scripted something to automate finding the play area, pipe orientation and click the solution. https://www.youtube.com/watch?v=kIpyQRBuwt0

Really bad code here: https://github.com/justecorruptio/hexapipes

corruptio··on Game Boy Wordle clone: How to compress 12972 five-letter words to 17871 bytes
oook did some experiments... just counting the size of the delta streams: 17346B for 26^4 and 16852B for 32^4 (as described above)

interestingly, the sweet spot is a mix at 30^4 at 16797B

corruptio··on Game Boy Wordle clone: How to compress 12972 five-letter words to 17871 bytes
oo oo, idea... trying to implement it now:

With 5 bits per letter, you have 6 symbols left over. We can use those to represent alternate pairs like "A or E", so you can encode BANDS and BENDS at the same time. Looks like if you pick the 6 highest frequency replacements for each starting letter, you can reduce the full word list size by ~2k words.

A naive lookup table for the replacements is 26 * 2 * 6 = 312 bytes.

edit: oops double counted the reduction

corruptio··on Python Default Dict
Reminds me of perl's autovivification, where you can even mix and match dicts, arrays, and scalars:

    $M{hello}[4]{world}[0]++
gives you:

    {
        'hello' => [
            undef,
            undef,
            undef,
            undef,
            {
                'world' => [
                    1
                ]
            }
        ]
    }
corruptio··on Corners Don't Look Like That: Regarding Screenspace Ambient Occlusion (2012)
> The tiny peak at the edge is probably because the edge between the two walls sometimes has white paint showing through, so it's not a lighting effect.

I vaguely remember an old graphics professor mentioning that this peak would exist because of reflected light from the other wall, though I can't find any literature after some light googling. Is this a real thing, or am I crazy?

corruptio··on Codec2: A Whole Podcast on a Floppy Disk
Having grown accustom to MP3 artifacts, it's strange to hear artifacts that are natural, but just aren't quite right. More specifically, in the male voice sample: "sold about seventy-seven", I received it as "sold about sethenty-seven".
corruptio··on A 220b spreadsheet app in HTML/JS
https://github.com/xem/sheet/pull/7 :D
corruptio··on A 220b spreadsheet app in HTML/JS
Here's another char off:

    (o=b=>{for(j in a)for(i in a)y=a[i]+j,b?document.write(`<${i*j?'input':'p'} onfocus=value=[o[id]] onblur=o[id]=value;o() id=${y}>`):eval(y+(".value"+o[y]).replace(/[A-Z]\d/g," +$&.value"))})(a="_ABCD")
corruptio··on Show HN: Hacking airplane headphones
Or, just stick a regular 3.5mm headphone jack into the two-pronged hole half-way in. The contacts line up in such a way that one channel touch both inputs. Just turn up the volume a bit.
corruptio··on Klisp – An implementation of the Kernel programming language
#define and &&

heh

corruptio··on Ask HN: Any Go players here? (Not the language)
I deeply urge everyone interested in go to try to play it in person. Nothing beats a live face-to-face game against someone and then being able to review it on a board afterwards. You'll also find that the people who go to go clubs are very friendly and generally love to teach beginners.

There are a surprising number of local go club around the country: http://www.usgo.org/where-play-go

Especially, if you're in the SF Bay Area (my area): http://bayareago.org/#local-clubs

corruptio··on Two problems I had to solve in my Oxford interview (2013)
My solution:

    0: Z 2
    1: Z 3
    2: J 0 2 -> 4
    3: J 1 3 -> 7
    4: I 2
    5: J 0 2 -> 4
    6: J 1 3 -> 7
    7: I 2
    8: I 3
    9: J 1 3 -> 7
Handles the zero case. Only uses 4 cells total.
corruptio··on Band releases album as kernel module
For the lazy, I'm no fun:

  curl https://raw.githubusercontent.com/usrbinnc/netcat-cpi-kernel-module/master/tracks/trk3data.h | perl -ne 'print chr hex' | mplayer -
corruptio··on 2048 implemented in 487 bytes of C
Author here. Per many requests, here is an annotated version https://gist.github.com/justecorruptio/10248923