HN user

petdog

114 karma
Posts0
Comments32
View on HN
No posts found.

This is a really great tool. If it could take the first .csearchindex going up the tree as the current index (somewhat like git does with .git dirs), it could easily top rgrep/ack for searching into projects. (just add line numbers and some match coloring)

Well, I can tell you that eating beans (pretty much required for a vegan?) and cabbage hurts like hell. In fact anything that is a little too gassy. Eating a lot less tomatoes helps too. Milk is annoying, but not cheese, and especially not yogurt. I think yogurt actually helps you. I have no problem with meat, except when it's too bloody.

Now, maybe I'm to blame here, using the nightly build of chromium, but webkit is a walking memory leak. Just for a comparison, I have the same amount of tabs on firefox and chromium and firefox is using 500mb of ram, while chromium is using 3.5 GIGABYTES. And I'm not even using it much. But really, the problem is easily reproducible. Just open whatever webkit based browser you want, and keep reloading the same moderately big page. Ram goes up, never to return. That works with a trivial program that embeds webkit via gtk, too. Or you can just look at the commits on webkit: a couple of leaks fixes every week.

It looks like you forgot to call the function in 'simple_catch'. Interestingly, if you do, manual_with_catch will actually be faster in the failing case. (A try:fn() finally: return True beats everything else in the failing case)

Poor man's skype:

sender

    arecord -f cd -c 2 | lame -b128 - - | netcat -u your-ip 6881 | mpg123 -
receiver
   arecord -f cd -c 2 | lame -b128 - - | netcat -u -l 6881 | mpg123 -

Actually, map is still faster:

    In [24]: timeit ''.join(map(chr, ll))
    100000 loops, best of 3: 3.91 us per loop

    In [25]: timeit ''.join([chr(i) for i in ll])
    100000 loops, best of 3: 5.85 us per loop

    In [26]: timeit ''.join(chr(i) for i in ll)
    100000 loops, best of 3: 7.79 us per loop

So by "hidden features" they mean "can be found in the first pages of any tutorial"

(Ok, I didn't know about re.DEBUG)

EDIT: I'm not claiming this link is worthless. But I'd call it "great features of python" or simply "features of python"

Reddit needs help 16 years ago

> /r/pics? /r/askreddit? /r/iama?

What? /r/iama is one of the best things that happened to reddit. Sure, most of the submissions are shit, but some are golden.

> What does reddit offer me that I can't get elsewhere

The community. Most of the value is in the comments.

---

About usenet, you could try http://www.astraweb.com/

I bought the once-off 180gb plan. Text isn't even counted. It's going to last me years.

It's not broken at all, and not in any way peculiar to javascript.

    >>> map(apply, [lambda:i for i in range(5)])
    
    [4, 4, 4, 4, 4]

    * (mapcar 'funcall (loop for i from 0 to 5 collect (lambda () i)))

    (6 6 6 6 6 6)
It's just that the looping constructs don't introduce a new binding, but modify the existing one.
    >>> map(apply, [lambda j=i:j for i in range(5)])
    
    [0, 1, 2, 3, 4]

    * (mapcar 'funcall (loop for i from 0 to 5 collect (let ((j i)) (lambda () j))))
    
    (0 1 2 3 4 5)

> However, electrophoresis can only sort them by weight.

> To check for allergy to a specific allergen, [...] Repeat for every allergen.

Hah! If only we could run a binary search.