skysight-inc/HackerNews huggingface dataset:
> That may be a byproduct if the language implementers then make the social mores they admire the ones that perform the best

I understand the definition of the word idiom. I'm saying that the quoted scenario is, in fact, not just hypothetical, but likely. Thus, following idiomatic style can help one avoid performance issues.
I think everything is saved in flat files in a directory structure.
I've seen lots of js projects that have a jQuery dependency for the sole reason of selecting elements.

It's fairly trivial to cook up a simple jQuery like selector but others have already done it: e.g. https://github.com/ryt/Selector
> I, too, think like that, although Ruby's nomenclature frequently confuses me.

Most of them come from Smalltalk's Iterable protocol[0]: that's the source for `select:aBlock`, `collect:aBlock`, `inject:thisValue into:binaryBlock` (Smalltalk uses `fold` when there's no starting value, and `inject` as "fold by injecting initial value"), `detect:aBlock` and `reject:aBlock`.

Smalltalk also uses `do:aBlock` where Ruby uses `each`, likely due to `do` being a keyword in Ruby.

Also, `find` is not `filter` (that's `select`, aliased to `find_all`). `find` is also `find` in Haskell[1] (and maps to Smalltalk's `detect`, also useable in Ruby).

> 'find' collides with ActiveRecord

Uh... no, ActiveRecord collides with Enumerable, I'm pretty damn sure Enumerable came first.

> how do you do filter in Rails?

What's wrong with #find? Or #where? Or #find_by_*? Same name, different namespace, different meaning. Kind-of the point.

[0] http://www.gnu.org/software/smalltalk/manual-base/html_node/...

[1] http://hackage.haskell.org/packages/archive/base/latest/doc/...
There's two ways to tackle that - either stick to the slow overnight charge, or have a home charging station with a stonking great capacitor bank which itself recharges slowly while you're out driving.
It's also every employee's job to honestly and openly argue with anything that he finds stupid or unnecessary. If he doesn't speak up, or if he loses that argument, then yes, he is supposed to commit to the decision that's been made and execute it to the best of his ability.

Conversely, it's every senior employee's job to listen to these arguments in good faith and countermand his own bad decisions once they've been pointed out as such.

What isn't anyone's job, ever, is to receive instructions from above and silently ignore them. Especially in this particular example, a manager who hasn't had a 1:1 with any of his reports in half a year probably isn't some brave conscientious objector trying to hide from the oppression of the CEO, he's more likely a shitty manager and the people working for him would probably be glad to see him summarily fired in the first place.
That's a nice thought. But the real reason they do it is market segmentation; e.g. when I looked at it two years ago, the Canon T3i was infinitely better and cost less than any IP camera out there. If they let you stream out of it live, it would kill the ip camera market. So they don't.
When you say not supported by default do you mean not supported when the user doesn't have a JRE installed?
If the situation was that way fore 6mos before he noticed it, I think it's reasonable to speculate that "the culture he's worked hard to build" is at least partially imaginary in Ben's head.
A lot of the people out there using iMessage don't even know it. Because it hooks in so transparently with text messaging, people who used to SMS between iPhones now iMessage between them and many don't even realize that anything has changed.

Among those who do know the difference, my experience is that by far the most common reason to use it is to avoid paying for text messages. (I'm in the US here, so it's common.) A secondary reason, but really secondary compared to that, is the fact that it works on other iDevices, not just iPhones.

Until I read these comments, it didn't even occur to me that security might be an advantage of iMessage. I think the number of people who use iMessage because of that is roughly zero.
"which is that some people are all too aware that they get NIL karma from a submission unless they are the very first to submit that link"

As a side note to this if you submit a link that has already been submitted you bump up the karma on that by one point. So even if you submit a link first (by the method you describe) and it doesn't make it to the front page or get "organic" upvotes the mere fact that someone else has the same idea, but was a minute late, gives you an extra karma point.

Added: So the conclusion is that if you are trying to get karma it pays to spend time adding the obvious suspects rather than the outliers (say a story from the NYT or Techcrunch that others will do the same.)
Ruby for-loops have unusual scoping of loop variables, and if you're not familiar with this it can prove to be a source of bugs. I was bitten by this some years ago when I was first learning Ruby, and it took me a while to track down the problem.

An "each" block has the scoping you'd expect, and is more consistent with the rest of the Ruby looping constructs (like select/filter or collect/map). It's not a huge deal, but there definitely are technical reasons not to use it.
I want to direct this towards the folks commenting here who might be in the anti-Apple camp. Yes, a walled garden is no fun for anyone once it reaches a critical mass. We're sort of starting to see this with Twitter, with their recent API adjustments. Decentralized and open platforms are also really tough, just look at OpenID. The adoption is not there.

Apple saw that the current SMS implementation was flawed in many ways and sought out to improve/replace it. For example, all of the carriers (at least in the US, with the exception of the underdog Sprint) charge an exorbitant amount of money just to send/receive text messages. I pay $20 per month for that ability. SMS also has a limit of 160 characters. It also only works via cellular, whereas iMessage works via data connection. This is awesome for me, as I live in the boonies where I don't always have a cell connection (but do have excellent wifi). Being able to reply from multiple devices is also nice. Let's not forget all of the little 'nice-to-haves' like knowing when a message has been delivered and/or read, knowing when the other party is replying, etc...

Alas, they did this because the carriers wouldn't. Prior to Apple releasing the iPhone, you couldn't buy a phone that didn't have some one-off UI, preloaded with garbage apps, etc... Apple forced the hand of the mobile industry with their iPhone (this is obvious to many, but concrete evidence exists inside of the Samsung vs. Apple court documents recently released)

Apple is now doing this again with iMessage. They took something that really needed revolutionizing, and did it. It began as something great for members of the Apple ecosystem. They used their users and platform to prove it, and it's been successful. I can communicate via my Mac, iPhone, and iPad in a (mostly) unified experience. So, I do agree and hope that this expands to a wider audience. That being said, it will be tough. An open consortium leads to all sorts of issues (ahem, Android) and sometimes having one chef in the kitchen yields the best overall experience for everyone (Apple).
The implementation of 20% time is incredibly variable across teams, and even across individuals. I've never had to pitch a 20% project to my manager, or even notify them that I'm working on it. For many past ideas I ran it by them just because they might be aware of people that can help me or related projects I might want to look at, but for my current 20% project (an eventually open-sourced library), I didn't even mention it to him until I went up for promotion, when a peer wrote "Oh, by the way, his 20% project will have a big impact both on our team and on the world at large", at which point my manager was like "Maybe we should make this an official OKR and part of your regular job duties." That actually happens a lot - I've had a bunch of 20% projects that I mention to management and they're like "Oh, you should feel free to take some 80% time to finish that."

I also find that the definition of 20% time varies a lot between individuals. For me, it's "All that time when I have nothing better to do, when I get to work on whatever I want" - in some weeks, that can be 80%, in other weeks it's 0%. I have a friend who spends one morning a week working at Google Research, and that's his 20% project. I have another friend that taught Lego Mindstorms to 5th graders one day a week, and that was her 20% project. I have another coworker that started working on a new project (sponsored by a different VP), and that was his 20% time. I have a few coworkers that basically do whatever they want - actually, my job description is pretty much like this now - and so it's all 20% time.

Actually, for a lot of my coworkers, the reality is probably much like it is in many other large organizations with decent management: "As long as you get your work done and are aware of the organization's priorities, you can do whatever you want." I know someone who moved to Uganda without telling his manager and regularly works from Paris, Thailand, Budapest, Vienna, Prague, etc. - his manager doesn't care, because he's responsive to e-mail and gets his work done quickly.
The article says "Restrictions on Internet gambling in the U.S. may also ease." Both Bloomberg citing the "U.S." as a whole and these states bucking the anti-gambling trend (historically states have been pioneers for trends in federal legislation) might (I said "considering") mean the US (= federal) will some day let those transactions be ... honored.
Why not build a web app?
The problem I have with HN at the moment has nothing to do with what is on the front page but everything to do with the tone of some of the comments - there has, as far as I can see, a rise in quite openly hostile and blatantly rude responses which I really don't remember seeing in the past.

NB One thing to note is that I'm not talking about sw007's experiences but comments containing lines like:

"So slow clap for writing some useless crap. Sorry for the vitriol, but this shit is just dumb."
Right, I think where people have to get over themselves is that teaching something is often very different from using something. When I was being trained as a chemist, I was started with techniques that were over 150 years old, and that no one in their right mind would use in a professional lab (you really think chemists do tedious titrations when you can buy a pH meter that's 10x more accurate?).

In other words: programmers don't understand pedagogy. Nothing really new there.

I've very much enjoyed the books though...went back and did "Learn C the Hard Way" even though I've been using C for almost 18 years. Can't wait to read "Learn Clojure the Hard Way"... ;-)
I think the power consumption advantages of APNS come from the fact that it's built into the OS and it's multiplexed, meaning that you only ever need one persistent connection/monitoring/etc. no matter what needs to listen. If you did XMPP directly, you'd need a separate background process and connection just for that, in addition to APNS. If you had two different apps doing this, then you'd need two processes and connections, etc.
I am the author of a notable amount of Ruby code. Also, for loops are syntactic sugar for .each in Ruby, so maybe you should go learn Ruby?
As far as I know, this has been changed in Python 3. See: http://stackoverflow.com/questions/3815359/while-1-vs-for-wh...

It may be the case that at any given point, the idiomatic way is not the fastest. However, if idioms are widely adopted, the language implementers have good reason to optimize them. I'm not saying that's what happened in this case, but I think it's reasonable claim to make in general.
Oh, no; I've seen just as much up North as down South. I'm not talking so much about severe racism; just the more everyday "Maori are lazy, the Asians steal our jobs and our houses, the French are poor workers..." I guess I should call it racial prejudice, rather than racism. "I'm-not-racist-but" racism.
Now that's a little harsh. The fact is, every company where I've seen the internal wiki go stale is also a company that is otherwise incredibly successful. Though important processes were also documented by some additional formal process, and the wiki was a lower-priority thing anyway. Or at least, important wiki pages seemed to be better maintained.
python + pyside + {py2exe, py2app} is pretty nice, but it still has the problem of users having to find a file that they downloaded to run it.

If you know what browser they're running the extension apis for firefox, chrome, and safari give you access to the OS and the ability to run your own native code.
All great managers are great.
And if all great managers are the same, then there is nothing to compare!
Zed is making a number of points, so I don't want to sound like I'm arguing against all of them. But particularly on the matter of each... if all we were talking about were each I think Zed would have an excellent point. But wrapped up with each are all of the other fantastic enumerable methods like map/collect, select/find, inject/reduce, as well as each_cons, each.with_index, map.with_index, etc. These are where the power and expressiveness of ruby really come into play. For example:

users.select(&:meets_some_critera?).each(&:update!)

You could totally do that in a for each loop if you wanted. But it isn't really composable. While this works for the basic update...

for user in users do
user.update! if user.meets_criteria?
end

... what if you wanted to then sum up the new account balances? In the first example, you'd just chain on a couple more enumerable methods:

users.select(&:meets_some_critera?).each(&:update!)
.map(&:account_balance).inject(&:+)

With the for each construct you'd have to pass in an accumulator variable and keep track of whether to sum or not. While you certainly can do it in a for each construct, I'd argue that you'd be missing out on what makes ruby, ruby. And getting beginners in that more functional(ish) frame of mind sooner rather than later is a very good thing.

--edited a few times for formatting/clarity
Depends on what kind of encryption they are using. If they have implemented public/private encryption, where the virus only have the public key, then yes it would indicate some form of sophistication.
Not at all likely, and in fact if you believe this without first investigating its validity then you may be bit by bad performance. A very real scenario is that you use something blindly because everyone else does, thinking it performs well, and then you find out it actually doesn't.
Record $4B Raised In Mobile VC In The First Half Of 2012, 25%+ In Consumer Apps
The 24 hours bit is a little harsh, but let's be honest here--saying "do this or be fired" is brutally honest, nothing worse. Any other way of putting it would just be a euphemism for "do this or be fired", and euphemisms are bullshit.
no! it's crucial to my daily usage. its loss is killing me.
I'm pretty sure Zed knows Ruby quite well.

FWIW, `for .. in` is syntactic sugar over `each`
Show HN: How a developer learns to play the guitar (Angular.js)
for-loops and .each had weird scoping rules until Ruby 1.9. In Ruby 1.9 for some weird reason they fixed .each but not for-loops. No idea why. So, if you're saying use .each for technical solution to a problem in Ruby, then your proposed solution only works in some versions of Ruby.
They mentioned the race to Pike's Peak in 2010; apparently the Audi did it in 27 minutes (whereas the record is close to 10 minutes): http://www.wired.com/autopia/2010/11/audis-robotic-car-climb...
The car sure has made a lot of progress in 2 years...
"Self-links are OK only if they are really good. If someone sits around posting every post on their blog to HN (or having their buddy do it) "

Along those lines I'm wondering why a few words by the OP on this subject simply asking a question and offering nothing more deserves to be on the front page.

The OP is Josh Miller (by handle) who works at branch.com where the simplistic post appears.

This essentially appears to be publicity for branch.com.
Well, at this stage Assange has become a pawn in the game of international relations. I wonder if he envisioned that, when he was dreaming of how "Wikileaks" would change the world.

Countries that generally get a raw deal in their dealings with the US, like many in South America, can use him as a bargaining chip. And that's exactly what's happening here. Reading between the lines, seeing beyond the silly headlines the papers are feeding us, does not require you to be a foreign policy expert.

As someone said in an earlier post, whether we like Assange as a person is less relevant than the fact his ill-considered actions have pushed the envelope and are forcing some issues about the internet to be addressed, the resolution of which hackers have been patiently waiting for many years.

It's interesting to think about all the cables that were never released, i.e. the vast majority of them. How did the newspapers decide which ones to let the public see? Those decisions are having real effects. They were in essence policy decisions. Someone at the news corporation had to say, let's release these cables about Ecuador.

And here we are.

Pass the popcorn.
"to complement our web app"
He's from India, I expect he means some sort of genuine tourist entry visa. Never been to the US, so I don't know about its visas, however.
I would change the cache timeout: http://amitu.com/2012/08/why-hacker-news-sucks-off-late/
Awesome stuff! But wont you get into trouble with Google for this site? Because it is like Spotify, except much better. :) Previously, I used http://www.youtube-mp3.org/ to conveniently listen to music on youtube, but it apparently ran into legal issues.
You are right, and once again I am not against using functional programming, OOP, message passing, or any of the things I mention about .each.

I'm against using .each as a first looping construct. In fact, go look at your supposedly better last line of code and tell me if you think a newbie would even begin to comprehend that? Hell I'm a programming veteran and Ruby veteran and I want to metaphorically punch you in the gonads for that line of code.
"I'm feeling lucky" no more
Awesome :) any plans for last.fm scobbling integration?
Look into Qt. It's cross platform and widely used and I think you can even use JavaScript if you aren't familiar with other programming languages.

Also personally for a simply program I would not have the users install it. A self contained executable would be sufficient and less of a hassle. You can still put store data in the user's own configuration directory.
Please, goto/jump .. reminds me of the rant about not being able to implicitely couple two function with global variable mutation in functional programming.
Denmark has a national personal identification number [1] and a reliable land registry system. The UK has had the latter in modern history. A democracy with social welfare programmes could theoretically exist without a reliable identification system, but one would expect that to lower systemic efficiency and barriers to fraudn and corruption.

The nut of my argument is that the Indian system is not substantially more instrusive than photograph + address based systems used in the developed world. Hence, the emotional backlash against the Indian project should not be held independently from identification programmes around the world.

[1] http://www.cpr.dk/cpr/site.aspx?p=303
U.S. Marine Arrested for Facebook Posts
The concept of a jump is not one you want to ever teach, and I think you've chosen to go into more detail in one list than the other. In terms of "what does it do", both bits of code call "puts elem" on each element of the array. In terms of "what it's actually doing", the .each example is forming a block and passing it to a method, while the for example is a special syntax with its own scope implications. So the complicated parts of the .each version (blocks and method calls) are general concepts used throughout the language, that you would always want to teach to learners sooner or later. Whereas the complicated parts of the for example - the scoping and the for syntax itself - are dead ends that don't help you learn the rest of the language at all.
It depends upon your language of choice; I'd advise you to use a well known and well supported cross-platform GUI toolkit (by order of personal recommendation): WxWidgets, Qt, Gtk, Tk, GNUStep,Fltk ... It largely depends upon your familiarity with the toolkit, the quality of available bindings for your language of choice, and the importance (or not) of having a nice GUI, following more or less closely the host system visual guidelines.

Generally I'd naturally go for WxWidgets, which is mature, relatively easy to use, provides bindings for about any language in common use, and gives a good look-and-feel and OS integration on Windows, Mac OS X and Gnome/KDE desktops.

Many people (more often Apple purists) will pretend that cross-platform toolkits are ugly and don't fit well anywhere. That's blatant nonsense, IMO; nowadays in fact it's quite the opposite, even the old cranky Tk can be made decent-looking without much work (but good knowledge of its internals).

Java applets are a real problem mostly on windows, because windows hasn't come with Java pre-installed for a very long time; the JRE is a complete PITA to manage (long, slow updates about each time you need it...), then Java desktop apps have pretty horrible startup time and heavy memory usage. Python, or Perl, or even C/C++/ObjC are probably saner and easier choices overall.
> In the process I've stumbled on what Rubyists call an "idiom", the use of .each to do loops instead of a for-loop. To them this is one of the most important signs that you are a real Ruby programmer. They look at this usage of one looping construct over another as some sign that you are incompetent, and haven't been properly indoctrinated into the Ruby community's ways.

As a Smalltalker, I think select/find/collect/each to be wonderful things, as they are of the same spirit as the do: collect: select: reject: methods in the Smalltalk Collection methods. That said, I find the notion of stigma attached to certain constructs to be counter-productive. In my experience, such attitudes are more about socially scoring points and vying for social dominance than they are actually about improving the community's code. However you get the functionality done is fine, so long as it's short and understandable.

(Such stigma attached to situations where people could use inject:into: but didn't was often counterproductive to readaibility in the Smalltalk community.)
Just to be pedantic, it is actually the Smalltalk "do:". :)
Oh, no concern at all about the ruby style guide. I even point people at it in the book so they can start grasping and writing code with other people. My mention of the guide is not intended as a knock on the guide at all.
Thanks for getting those out of the way guys, both were getting tiresome.
Yes, and it also seems like Java applet support is not switched on by default in many (most?) modern browsers.
Added a play toggle to the demo page.
The only problem I see with this analogy is that "Development" and "Programming" is an entirely different class of job as "Register attendant at a cafe."

If it was the owner of the cafe who did this, then that'd be really strange, because obviously the owner probably does (or at least should) have the "big picture" in his/her mind. But some lowly employee who checks people out at the cash register? Of course they dont see the big picture, its not their business to.

Good points though, although they are all kind of a no-brainer in my mind. This seemed a lot more like a chance to articulately vent frustration, than actually making any real points or major revelations.

Sorry your family got hassled like this.