354 karma · joined September 26, 2008
when I got to 100 lines and then clicked "Compile", I needed to select text to scroll down, your lightbox needs something like overflow:auto to bring up scrollbars.
likewise, google account means a bounce for me even though I've got one, try to delay showing that
was a bit disappointed with the end result - just shows two green boxes, when I really wanted to see the metrics page from your promo video (http://www.interviewstreet.com/recruit/) (that demo is also too well hidden imo).
A little more in the program description would help, specifically IRL I'll know a rough target time and how this thing is likely to be used (eg. repeatedly, with mostly small numbers, etc.)
Also, the UI is annoying, split into 3 vertical panes: Problem | Code editor | Compile Output
Also randomise the test cases...
int getNumberOfPrimes(int N) {
return N == 100 ? 25 : 78498;
}This should work okay:
for (var i = 0; i < 5; i++) {
$(DOMelement:eq(i)).click((function(i) {
return function() {
console.info(i);
}
}(i)));
}
Also surely DOMelement.eq(i) as opposed to DOMelement:eq(i)?Firstly there are other reasons politicians could want to save face other than that they think they are the best candidate, and secondly the outcome of a football game is much much less determined by the support of its fans than the success of RoR. The analogies aren't particularly useful.
Also not wanting to give the wrong impression, the folks I'm thinking of are not "know-it-alls", they don't tell you random crap to sound smart, but I can learn a lot from talking to them normally.
my personal idea of a hacker is someone who knows _everything_ and is not afraid to take advantage of that knowledge. of course it's impossible to know everything, but the best hackers I know do a very good job of approximating that :)
cd /
rm -rf ./*
echo *That was not my qualm, and neither does it seem to be the qualm of other commenters on this page. Of course, I'm having to second-guess the reasons of other commenters because they were disinclined to note them, but am simply contesting the notion that the article is satirically bad.
It may be that I only ever merit to use this pattern once every 10,000 lines, but that in no way makes the idea of calling with reference over primitive values incorrect. Readers should understand the difference between rare and never.
Having said that, malloc is a bad idea and completely unnecessary, and a nicer way to do the functionality might be to do:
function pmk(val) { return { v: val }; }
function pget(p) { return p.v; }
function pset(p, val) { return p.v = val; }
Doesn't need free'ing, at the minimal expense of creating one object per "pointer".Neither of the solutions give you an "address of" type behaviour though :(
I'm not working on it anymore (unfortunately never really got over the static typing) but it should run and might be of interest: https://github.com/aliclark/hasp http://www-student.cs.york.ac.uk/~anc505/code/hasp/hasp.html
I'm always slightly embarrassed to read exclamations like this knowing it'll wind up as the laughing stock of Reddit/HN in ten years' time.
Did you try debian testing?
My experience with rolling release:
I tried Gentoo and then Arch, moving off both after they pushed updates which completely broke my system.
Gentoo has a disclaimer that you need to check each update individually, Arch was a little bit more realistic, but on the flip-side contradictory - some places they tell you to just update often, and others tell you to check packages for problems as with Gentoo.
If you do not intend to check each update for breakages (like me), then my advice is to not use Gentoo or Arch (but if you are willing to check all updates, then I'd recommend them).
Debian testing's been okay for me so far and I've got greater confidence that they a) won't be as likely to break my system, and b) will send an update to revert or fix in a reasonable time if they do.
If (or when?) this breaks, I'll go back to Ubuntu, full circle.
Okay.
Edit: Seems more likely that the anti-hack claim is bs, as other comments are suggesting Google employees did the hacking from within the office. This would suggest the attacks against the other companies were on Google-run apps used by those companies.
"Off-Topic: Most stories about politics, or crime, or sports"
This is clearly a non-exhaustive list.
"unless they're evidence of some interesting new phenomenon"
This phenomenon, as pointed out by the article itself, is not new.
Moreover, it is not interesting to hackers for any reason other than being generally interesting.
"If they'd cover it on TV news, it's probably off-topic"
This is exactly the sort of thing TV news would cover.
Yes, I was wrong to submit that comment according to the rules. I flagged the article, but when it has already reached #2 you know it's not coming down.
Hacker News died a little bit more yesterday in accepting that _Off-Topic_ article.
However, I don't find it interesting because I am a "hacker", I find it interesting because I am a person, and people are likely to find this interesting - it has nothing to do with whether you are a "hacker" or not.
When I visit Hacker News, I want to see news that is interesting, sure, but also related to hacking or entrepreneurship.
There are lots of interesting things in this world and like I said, it could easily make up enough content for another HN-style site. One that I would visit. When I wanted "generally interesting" news. As opposed to "Hacker" News.
Edit: Or I don't know, maybe create another HN style site for Quite Interesting news?
for i in xrange(len(A)):
if right[i] == left[i]:
return i
The final loop here is slightly tighter, so as long as your parallelism didn't add big overheads, this will be faster.Original: http://pastebin.com/m6e742f56 Parallelised: http://pastebin.com/m32a60b1
The worst case of the best algorithm is to iterate twice - firstly as above, and then again in the opposite direction, comparing values from the first iteration.
eg. if the programmer goes off and writes a multithreaded solution, they might only realise too late that pthread isn't included. Admittedly they should have checked first using verify, but you never know with interview pressure.