skysight-inc/HackerNews huggingface dataset:
Erlang is a functional language specially designed (and suitable) for concurrent programming.

His rant is partially correct (at best), especially looking at OOP from a functional programming point of view.

However, developers in the real world who doesn't focus on concurrent programming have different needs.

I'll comment his objections from a C++ perspective (which is a multi-paradigm language, not purely OO):

Objection 1 - Data structure and functions should not be bound together
- you are free to store all your data structures in a single file, and access them from anywhere. However, using classes will let you hide some of the data structures which are not necessary globally, reducing the cognitive load.

Objection 2 - Everything has to be an object
- Not in C++. You use classes where appropriate, and ordinary functions elsewhere. I agree that everything shouldn't be an object.

Objection 3 - In an OOPL data type definitions are spread out all over the place.
- similar to objection 1. You CAN store all definitions in a single include file, but for large projects this can be a LOT of data definitions, where many/most of them are only relevant for parts of the applications. Hiding data definitions in separate classes will make it easier to focus on the RELEVANT data depending on which class/function you use.

Objection 4 - Objects have private state.
- again, similar to 1 and 3. "State is the root of all evil". If you store all data in a single file, then you have one giant global mess. By assigning them to a class, you clearly state the responsibility and scope of the variables. A private state is nobody's business but the class. You don't HAVE to have private state for objects,but then you either need to pass all data to each function, or use global variables instead.

For Erlang (functional programming) these objections make (some) sense since you DON'T want any state whatsoever to facilitate concurrency.

However, saying that OO sucks is stupid, and the four reasons for why OO was popular is not even worth responding to. I don't think functional programming will become more popular due to this rant....
He said that only to establish a power relationship because that was how that company worked.

Well, establishing a relationship of respect and power is part of management, but there's absolutely no reason one needs to be a dick to do that.

Up until that point I had thought my manager and I were friends

That sucks, sorry to hear it. Maybe it's a sign of the times (I've only been in the industry about a year), or just the managers I've been fortunate to work under, but in my experience, coders always get more respect than to be bullshitted like that. It all comes down to money, I think:

If the company pays you less money than the wealth you generate, and provides good enough benefits/environment, you're playing a win/win game where everyone's happy. Yes, there are times when your interests diverge - your manager has a budget to minimize and you have a family to support, but those are exceptions to the rule.
Your web server can't issue a 305?

Your load balancer can't enforce usage limits?
Man, it's a tough way to solve his problem, but it would be hard to find a solution that is more hacker than this one.
> Additionally, he's run up against the pitfall with OO - it actually lacks a definition

I think OO is well-defined.

I would define it thus: an object is something with state and behaviour. An OOPL is a PL with facilities for handling objects. These facilities must include (i) specialisation -- either through subclasses or prototypes -- and (ii) method invocation determined at run time, so that for example:

someShape.drawOn(aCanvas);

their are several drawOn() methods and the one that is executed is determined at run time by the class (or equivalent) of someShape and possibly also by the class of aCanvas.
I agree.
If $700 Billion tax exemptions are given to start-ups they will create millions of jobs.
You are of course correct, but that's not related to what I'm getting at.

My question raised the point that the server would not be able to tell the difference, after an interruption, between session state that the client will hope to resume and session state that should be discarded. That state would accumulate until some routine cleared it out.
(1) The savings for "on demand" isn't in the water for the shower, but the water that cooled sitting in the tank and was then reheated.
(2) Many water heaters in the US are natural gas (or propane), not electric. It's far more efficient to burn NG to heat water than it is to burn it to make electricity and then use the electricity to heat water. Given adequate insulation (so water isn't reheated), a stored-NG system can easily use less energy than an electric on-demand system
(3) "on demand" water heaters can increase peak use. Stored hot water can be heated off-peak.

I don't know if there are on-demand water heaters that use NG.
Objection 1 - Data structure and functions should not be bound together

This is not true of "OO", it's just true of OO in languages like C++ and Java. These languages got OO horribly, horribly wrong; so if you use them and dislike OO, it's possible that you dislike the language -- not OO.

If you use CLOS, you'll see that functions are functions and data are data. CLOS just gives you some tools for calling different functions depending on the type of the data and for specializing subtypes. This is OO done right, and it is not what the author of this article is referring to.

Objection 2 - Everything has to be an object.

Everything has to have a type, yeah. But the line between "built-in type" and "object" should be blurry, and in CLOS it is. Again, if you are hating OO because of Java's implementation quirks...

Objection 3 - In an OOPL data type definitions are spread out all over the place.

I am not sure what the problem is here. Unless your code is all in one file, this is going to be a problem regardless of the programming "paradigm" you choose.

When writing Lisp, I often put all my class and method definitions for one chunk of the app in the same file. I think this is what the author wants to do, and it is do-able and commonly done in CLOS. In Java, yeah, you have to put each class in its own file. That is irritating, but the problem is not OO.

Objection 4 - Objects have private state.

This is true. I prefer to write OO code that maps one object to another, rather than mutating an object's internals. The sad reality is that this approach is slower and uses more memory than the mutation approach, but I think it's easier to reason about and maintain. Computers are fast, anyway.

So while it's possible to misuse OO, whatever that means for your particular tastes, it's also possible to not misuse it. If you hate OO, it is possible that you are doing it wrong.
Why there are no absolutes. Ever.
I agree that we shouldn't extrapolate too much from this one incident. But it's not like Google's super-secrecy policy gives us much choice. If anyone from Google wants to tell us about their deployment infrastructure and explain why this one incident really was a nigh-impossible black-swan one-in-one-billion-hour freak of nature -- or why Google has sensibly traded away a certain amount of uptime in exchange for a more flexible architecture (or, perhaps, more cash to spend on tasty gourmet pizzas) -- I'm sure we'll all listen with rapt attention. Until then, we get to tease them mercilessly. ;)

Meanwhile, I'm sure that the original submitter would agree that tests ain't perfect. If you read the link at the top of this blog post:

http://timothyfitz.wordpress.com/2009/02/08/continuous-deplo...

...you'll find that this isn't merely an article about automated testing. Automated testing is just a part of the mighty continuous-deployment ecosystem being described here. It isn't even the real heart of that system: The heart is a planned, well-designed, semi-automated routine for rolling back changes in production. They roll out a change to a subset of their servers, monitor for statistical anomalies in the usage patterns of real, live users, and only continue the rollout if there are no anomalies. If they run into trouble, back they go.
Recently I installed a script on my website to track peoples' mouse movements. First thing I noticed was a user just clicking around in circles in empty space.
Memorable IT meltdown -- for wrong reasons
I still really enjoy Malcolm Gladwells books.
It seemed to be well researched and well written. This is not omg-all-the-acorns-are-missing article.
"4. Start writing something!

Forget theory; forget mastering Objective C with your first attempt. Just set yourself a project and start working."

A couple days ago I stopped slogging through Kochan's Objective C book (made it to Chapter 7) and started coding. I think I was kidding myself that I could learn by reading - I think it was an indirect form of procrastination. For example, how will you ever learn that you need to use NSMutableString instead of NSString if you want to modify Strings?
TicketMaster and Live Nation Agree to $2.5 Billion Merger
His name is Kevin Gawthrope and he's on Twitter http://twitter.com/gawthrok
This reminds me of the time I attended a clinic taught by Marty Friedman (ex Megadeth guitarist). The audience had a few "purists" who seemed miffed that he'd strayed from his roots to perform pop-music in Japan. After being asked about the merits of his new endeavors he simply responded (paraphrasing) "Who wants filet mignon at every meal? Sometimes I just want a cheeseburger from a fast food joint".
As I noted elsewhere in this thread (http://news.ycombinator.com/item?id=475391), this article is not merely about automated tests. The author says that his company is using continuous deployment because it lets live, human end users bang on the code, as quickly as possible, in bite-sized chunks that can more easily be rolled back and fixed.
> not hardcoding it as a constant.

The bits have to be somewhere. The question is whether they appear one place per "meaning" or they're at every use.

Normalization is not just for databases.

> In any case, changing the string value here should be considered a program refactoring and done the same way you would do any other refactoring.

Which refactoring tools can distinguish "obj" (used as a prefix for object file temp names) from "obj" (used as a prefix for orange bear jumpsuit part numbers), let alone 0 from 0?
There are plenty of standards right now, why doesn't everything "just work together" yet?

Ad-hoc apis can be frustrating, but at least they don't make you suffer under the illusion that there's some magical perfection you're missing out on if only that wrinkle in how they implemented the standard got ironed out.

Loose coupling, tolerance of fucked-uppedness, etc., are why the web works at all. The web standards movement is dead, long live the web.
It's missing because you can't get O(1) and have each key equally likely to be returned, right?
Google's sheer mass and "better" integration with their own products puts it in a good position though.
are you sure? I don't think so. See the new version of the pseudo code. Just select a new random index every time you reach an empty bucket and you are done.
It's more of a disconnect of languages between business-ese and face-value English. The problem is when one is mistaken for the other.

If you're trying to hire a hacker and he says, "I'm really interested in your project, but I'm not ready to make a commitment right now", he's indicating genuine interest in your startup, and you might be able to get a "yes" from him in 2 months if his personal situation changes. If a VC says this, it means "no".
Typically you do not need to both randomly select one element and use them as keys in a map. If you do need both, the easy way to do it is to just keep the keys in an array as well as in a hash table.

The algorithm the author uses is not a good example. A simpler way to find the approximate most common elements in a large collection is to use a heap to store the (object, count) pairs. Still O(1), and you can remove the element with the lowest count each time instead of getting an approximation.
Another famous argument by Mises is that it is hard to figure out what is a socially profitable investment in absence of market prices. You pretty much just have to close your eyes and guess. The government currently doesn't justify each of the thousands of projects it has in such a manner.

I'm assuming we want the benefit of each project to be greater than the cost. The bigger the program, the more unlikely that is to be the case.

The critiques of the planned economy are applicable here.
Monnnnopoly!
National Bank (mostly Quebec)

Laurentian Bank (Quebec)

Canadian Western bank (Alberta, the West)

Vancity/Citizens (organized a bank outside of B.C.)
I wouldn't even mind so much if TM was less evil, but this is ridiculous.
In Ruby (w/ activesupport):

myhash[myhash.keys.rand]

Is an O(n) operation, for no apparent reason. At least in 1.9, they're obviously keeping track of the keys internally in an array to support the ordered hashes. However, when you do Hash.keys, it does a foreach on the hash and creates a brand new array.

I'm still not sure why getting a random key is particularly useful, but the real problem is that getting the keys of a hash should be an O(1) operation, instead of an O(n) one.
I truly feel sorry for you if your cell phone has a more stable internet connection than a desktop.
Although to be fair, we don't have that totally sweet "immune system" thing. I have to admit, it sounds pretty cool.
> I said that virtually all new pop genres have come from black americans.

What counts as a "new pop genre" and what definition of "virtually all" are we using?

Country/Western, Broadway, pre-rock pop
vs
Jazz, R&B/Soul, Gospel, Rap, Hip-hop
Fair Use Is Stupid - Idiots At The Wheel
The Fair Use polocies in the United States need to be changed, now.
Related (micropayments):

"One of history's ironies is that hypertext - an embedded Web link that refers you to another page or site - had been invented by Ted Nelson in the early 1960s with the goal of enabling micropayments for content. He wanted to make sure that the people who created good stuff got rewarded for it. In his vision, all links on a page would facilitate the accrual of small, automatic payments for whatever content was accessed."

Source: http://www.time.com/time/business/article/0,8599,1877191-1,0...
Python does have built-in support for getting an arbitrary key: popitem() on a dict. It removes the item from the dict, but you can always add it back.

http://docs.python.org/library/stdtypes.html#dict.popitem

Edit: This method returns arbitrary (not random) results; each element is not equally likely to be picked.
I don't think you can consider Austrian school of economics nor the Chicago school fringe economics. Milton Friedman and Friedrick Hayek were hardly fringe loonies, but rather continued the free market tradition of classical economists such as Adam Smith and David Ricardo.

You mention that you should settle down in a range between Krugman and Friedman. These are so completely opposite in their beliefs that you would end up believing nothing. -1+1=0. There really is no such thing as one mainstream economics, most economists are in one of these two camps Free Market or Keynesian.

I would also like to take issue with this using me as an example of "this element of going from socialism to the another extreme".

I grew up in a society (Denmark) where Socialism and the particular flavor of Socialism (Democratic Socialism) I believed in was mainstream and not at all considered extreme. When I look at the beliefs I had, they were pretty much the same as mainstream democrats have in the US today. I can accept libertarianism as being extreme, but in most of the world democratic socialism is not considered extreme.

I take pride in the fact that I was able to independently of anything but my own observations realize that this system, where I was living (Denmark) and my own party was corrupt and change the fundamental beliefs I had grown up on. Yes being a geek, who constantly question and optimizes things probably was an important part of this.

I think just accepting the status quo is impossible for a hacker, or we wouldn't have tech startups, open source or any other tech project that wasn't sponsored by DARPA.
>> Like the punchline to the how many philosophers does it take to change a light-bulb joke, I have no answers, only questions.

hah.
> Note that nowhere in this future am I writing any code. I don’t have to.

This is where I get confused.
Why do all changes have to end up in production immediately?
Is that question so beyond the pale that it should be downmodded instead of answered or explained away?
Wouldn't you say that the fact that you have to work harder, even with amazing sources like Rhapsody and Pandora (which have a cornucopia of indie music) to find good music means we're in a rut? In the '90s you could just put on the radio.

I couldn't think of a better way to define one.
lacker the example was just useful to explain how sometimes it can be useful to run randomized algorithms with hash tables. A real world example is a DNS cache that can't hold more than N elements, you can just remove one at random. Another one is a cache where elements can expire, and you want to perform a lazy cleanup.
Blogs: The Honeymoon is Over
No, they're duck-typed. Types are attached to values, not variables, and for example trying to eval (+ 1 "hi") will throw a proper type exception.

You usually don't have to declare types but for example in Common Lisp you can optionally declare types for better performance in speed-critical parts of the code.
Python is a pure OO language; everything is an object. Java is impure; primitives are not objects. Python is not an everything-must-be-in-a-class language, like Java. Python allows you to create a variable or function without having to put in a class. Much better, I think;
Sellers crumble after eBay cuts feedback
Now if only this worked for those people who miss the toilet when taking a crap.

I have a solution to the problem, however I don't think there's a fecal floor sensor yet and I doubt people would go into a stall with a shotgun aimed at their head so I fear it wouldn't solve the problem but shift it to the shotgun-free stalls.
Cellphones: always connected to cell towers. Conneciton isn't great but its almost always there.

Laptop: network changes as you move from one wifi hotspot to another.

I'm advocating moving his ssh connections to route through the android rather than directly from the laptop to the server.
Comparing this recession with the last 5 ones
Ask HN: What will you be doing when the unix timestamp reaches 1234567890, next friday?
Next friday evening, february the 13th, the unix timestamp will be exactly 1234567890, this is definitely a day to celebrate :)

What will you guys be doing?
I can top that!

How to write an iPhone app in ONE easy step:

1. Write an iPhone app.
Which ones don't you agree with?
That makes sure the code is consistent if the user refreshes the webpage or just visits it the first time. But what happens if the user just keeps the AJAXy web-page open for hours (as I do with Gmail for instance)? If you deploy too often and both frontend+backend code are in flux, you're more likely to end up with an inconsistent code state.

I guess you could make the frontend code aware of the code version, include it as a param with each XHR request, have the server check versions and return a "version mismatch", and then produce some alert on the browser asking to refresh the page. But this would tradeoff far too much usability.
So nobody in your group of friends or coworkers is on Twitter. And I have no idea how many of the total users of Twitter are 'real' people, but I can assure you that I use Twitter regularly to communicate with friends and coworkers and it has become my primary source for information. I usually find out about breaking news stories from real people at the scene, sometimes even before it hits TV.
hoping the world doesn't explode since it'll also be friday the 13th.
It does seem much more agreeable when you look at it as being a "pre-interview".

I know when meeting someone in person it's pretty easy to tell how passionate they are about what they're doing (or even how comfortable they are with their ideas). I do hope that you'll write about the results of this particular experiment once its done, I'm curious about how it turns out for you.
Agreed. Personally I see ID as an insult to religion, 'God' created the universe yet apparently he has to interfere 14 billion years later to create mankind because we're just so special, making him just so incompetent and not a true supreme being.

I mean why worship the supernatural if it's just not unbelievable. I mean at least the Greek and the Norse gods knew how to have fun!
If anything, that's a reflection of the shift in popular musical taste. Kids these days are, in my opinion, much less mature than those that grew up a decade ago. And it's their taste that pretty much dictates what we hear on the radio.

But as far as music production, I think we've definitely seen a boom in music exploration and creativity. Again, a lot of musicians are finding niche audiences -- audiences too small and insignificant to record labels who are looking for the next Fallout Boy.

I'd agree with you in saying that the music business is in a rut, because its goal of marketing the next hit artist for huge returns leaves a lot of talent unnoticed. But is music, as far as its creativity, originality, progression, and meaning, in a rut? I really don't think so.
Still from this page: http://en.wikipedia.org/wiki/Heap_(data_structure) I can't see how it is possible using an heap to count most common elements in large collction, without approximation, and using constant memory. May you please argument better the original comment? Thanks
Ask HN: How do you read RSS feeds?
What RSS reader do you use? What features do you like, or want from it? How many feeds are you subscribed to? How do you read them: Skim all posts? Read everything? etc
he ran out of steam/coffee :p
lukewarm or confused response

I have often posed questions here about things I've been doing for years just to see what others are doing or if there is a better way. Invariably, someone tells me it won't work when I already know better.

This tells me 2 things. I've encountered someone who speaks when they should be listening (what else is new), and, more importantly, that I'm pushing the envelope enough to make otherwise knowledgeable people uncomfortable. Good.
Hmm, yes, I think you are right.
> run by optimization algorithms

What is the evaluation function? How do we measure?

For example, we may agree that leaving houses empty is a bad idea and disagree as to whether we should leave them in the hands of folks who couldn't afford to buy them or to foreclose and sell them to people who were priced out of the market before.
Let there be retards - the Creation museum
I use Google Reader. I skim the headlines and read what I find interesting in full.
I use google reader, I subscribe to around 200 feeds. I keep trying to cull them -- but I just miss those few blogs.

I'd say about 5% of the feeds I get interest me.
I don't want to defend Google per se, but their uptime results speak for themselves. I don't see how a rare bug necessitates mocking.

And I agree about resiliency of the deploy -- it's what I meant by sophisticated testing of these momentary guinea pig users. Google's presentations on this stuff are about analysis and data gathering of changes both for immediate functional snafus and user preference for changes. i.e. probably state of the art in this regard.
www.google.com/reader

I subscribe to anything interesting and then unsubscribe from everything that has too many posts and/or proves to be too boring :)
not only is it possible, it’s just one part of my day job

A necessary, but not sufficient, requirement for a nimble start-up.
I was thinking of doing a basic Django + Selenium + Hudson continuous integration how-to blog post, but this blows me out of the water :)
I use netnewswire on the iphone..