News for hackers. Stuff that matters.

name_censored_

Re:What happens to your bike after it’s stolen on Wednesday December 31, 2014 @05:56AM (#8818898)
Bait bikes of a make/model make sense in a sufficiently bureaucratic organisation because it makes purchasing, tooling and technician training a hell of lot easier. Police cars (Crown Victorias) are obvious for the benefit of a few chases/crashes, when police fleets could have been a bit more surreptitious. I don't see a large organisations doing any different in selecting a "perfect bike to steal".

I assumed cheap bikes because of Ainmats[1] ratio of 1 in 100 bikes being trap bikes. 1 in 100 in any reasonably-sized city means tens/hundreds of thousands of dollars of kit (including GPS), and anyone with that kind of scratch has someone trying to minimise expenditure. Or, why spring for a Trek Butterfly to catch a hungry junkie when a Huffy would net hundreds of the same?

[1] https://news.ycombinator.com/item?id=8818498

Re:What happens to your bike after it’s stolen on Wednesday December 31, 2014 @03:55AM (#8818652)
Only three problems with that:

Firstly, bait bikes are inevitably going to be cheap bikes. Thieves are more interested in expensive bikes - and if the expensive bikes are not only more profitable, but also safer to steal, then they're bound to step up their lock-picking and angle-grinding game.

Secondly, finding someone to organise this would be difficult. Any single organisation sufficiently large enough to do this would be bureaucratic enough to insist on the same make/model of bike (for the obvious homogeneity benefits), which would make them as obvious as an undercover Crown Vic. Conversely, any kind of grassroots or community effort would (by design) need to alert as many people as possible to the venture, including the bike thieves themselves - thus spoiling it before it even begins.

Finally, these things are chop-shopped almost the instant they get on-sold. Tearing a bike down can be done in a public park in 5 minutes flat with a pocket's worth of tools. The bike thieves can adapt a lot more easily than the sting operators.

I'd be astonished if they use FPGAs in production kit. Once they get the circuit design right, even a modest quantity of (static) ASICs would be cheaper than FPGAs, and probably faster.

That said, if this really takes off, I'm sure some enterprising spirit will write some software to re-purpose these things as-is (I'm thinking something like a VMWare driver to turn them into NVRAM-SANs for disposable "worker" VMs)

It reduces energy usage, but also the useful lifespan of servers. Commodity servers can be pushed into different (lesser) roles when they get older, but specialty kit cannot. More specialty kit means more e-waste, and more e-waste means more toxic metals in the soil.
Re:The Bug Nobody Is Allowed to Understand on Saturday December 27, 2014 @06:57AM (#8802345)
> I think this is something that should be understood far more - I've seen far too many developers basically give up when the execution of the code they're debugging goes into something they didn't write or an exception happens in there

Those other devs may be suffering from a kind of "appeal to authority" fallacy - they assume that this release-grade third-party code section must be correct.

Or, it may be that they know that even if the problem does lie in the third-party binaries, the only fix is to submit a bug report. Since a bug report with a comprehensive steps-to-reproduce is more likely to get addressed than one with an ASM trace, it makes sense to focus effort there.

Or, it may be that they're clock punchers/overworked, and tracing someone else's code jeopardises them leaving on time/shortening their "in" tray.

Re:JavaScript Equality Table on Saturday December 27, 2014 @05:19AM (#8802236)
> Python: http://i.stack.imgur.com/Ya0Ux.png (I don't think all the entries are correct

Python checks out;

    >>> b=[True,False,1,0,-1,"","True","False","1","0","-1",None,[],{},[[]],[0],[1]]
    >>> for x in b:
    ...     print [int(y == x) for y in b]
    ... 
    [1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
    [0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
    [1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
    [0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
    [0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
    [0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
    [0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
    [0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0]
    [0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0]
    [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0]
    [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0]
    [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0]
    [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0]
    [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0]
    [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0]
    [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0]
    [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1]
Re:Oh Yes You Can Use Regexes to Parse HTML on Friday July 08, 2011 @07:56AM (#2742065)
>Now I understood the reason _why_ you can't use regular expressions to parse HTML is that HTML is usually not regular. Is this true?

I believe the reason is that HTML is a Type 2 grammar by Chomsky hierarchy (that is, a push-down automaton), whereas regexp is a Type 3 grammar (that is, a finite state automaton). To put it simply, HTML has a frame/state stack, and regexp isn't advanced enough for that (instead it reads "left-to-right" - no subroutines or recursion).

http://en.wikipedia.org/wiki/Chomsky_hierarchy

I suspect you might be right about him "cheating" using perl, but not knowing a lick of perl, I can't say for sure one way or the other.

Edit: Apparently, back-references mean regexp isn't regular - that actually makes more sense now; they've never quite meshed with my understanding of regular languages.

Re:Why I'm Rooting For Google+ on Saturday July 02, 2011 @06:52PM (#2722618)
>Lastly, IANAL, but I doubt promoting one of your products on one of your products is in any way illegal.

Wasn't that the whole issue with the Microsoft anti-trust suit - that Microsoft bundled ("promoted") IE with its other product (Windows)?

http://en.wikipedia.org/wiki/United_States_v._Microsoft