skysight-inc/HackerNews huggingface dataset:
I agree. Sometimes inline asynchronous callbacks work, just like inline code blocks for if statements or for loops. You just need to train your eye to read them as if they were inline code blocks for an if/then/else block or a for loop.

But sometimes when you get many levels deep in if statements or if a synchronous function starts to reach the hundreds of lines it makes sense to break it up into multiple functions that each have a sensible semantic meaning and which fit on a screen or so. This makes the synchronous code easier to read.

The same goes for asynchronous callback functions. The callback hell that I see most often happens when people have hundreds of lines of inception style anonymous callback functions inside of anonymous callback functions. In this case, just as with the synchronous function that got excessively heavy it makes sense to break things up into multiple functions.

It's all about finding the right balance, and when you do the results are very readable and easy to understand whether you are writing synchronous or asynchronous code.
Point taken. Sometimes I walk out of an interview and say to myself that the candidate did well, but just did not convince me that he/she really wanted the job. It may just be my personal perspective, but candidates that really stick the landing with me are ones that have that "let me at 'em coach!" attitude.
Most of the ugliness in stdlibc++ comes from the ugly ass naming conventions that are (or were) inherited to prevent conflicts. The quality of implementation in the STL is fairly high, if a bit old.
Yeah, I think the HSA was one of G W Bush's best accomplishments (and, probably, one of the only net-positive accomplishments other than helping in Africa somewhat), which is why I'm sad the new health reforms are basically incompatible with the HSA concept.

As I see it, there are basically two separate ways to make healthcare work -- expose consumers to prices AND give them the tools to make decisions (with subsidies, etc. if we want to let poor people consume more health care than other things, as a matter of policy; I don't think that's an economic argument), or have an external entity with the correct incentives acting on the consumer's behalf. Medicare seems to mostly work on the latter model.

It's clearly possible to screw up both ways, but an even surer way to screw up is to do neither/both-partially.

Ending employer deduction for healthcare (and/or making it deductible for individuals) would be a huge step, too (in either model). I see no actual upside to employers paying for health care vs. individuals or the state at all.
Weirdly, lots of folks I know at retirement age retire, then simply have no idea what to do with themselves. They've never cultivated a meaningful hobby or interest in the all the years of workaholism. The ones that vaguely remember something they wanted to do in their 20s find themselves fighting off a constant urge to sit in an office and work.

A few folks I've known worked until they simply couldn't, then died a few months later.

I'm reminded of my own father, who worked like a dog since he was a pre-teen, and simply hasn't been able to come to terms with retirement, choosing to start another job in his elder years instead of writing, painting and fishing which he has an obvious talent and interest in.

I tell myself that I won't succumb to this failure to live life and try to overcompensate a bit by traveling a lot, photography and many stalled attempts at writing. I wonder what would happen if I got fuck you money and if I could discipline myself to follow up to my passions instead of trying to fit them into my free time.
(C/OS developer spiel)

I'm sick of these app developers assuming that using "goto" is bad practice. The fact is that "goto" is used plenty in great production code you're probably running right now.[1] I'd like to know a cleaner way to abort a function into its cleanup phase when a function call returns an error. And "goto" statements are extremely simple to handle for even the most naive of compilers.

[1] https://www.kernel.org/doc/Documentation/CodingStyle (see chapter 7)
I was thinking this. I wonder if they also happened to get the 20 country code calls in addition to the 202 calls. Do they have any quality control on their code?
Sorry, I was trying to concede that you weren't making that point, but did it clumsily.

So here is the interesting question as I see it:

What's safer for developers, reading from /dev/urandom, or calling the platform CSPRNG when the platform CSPRNG does something other than reading from /dev/urandom?

I think the answer might be /dev/urandom. A Debian maintainer is not going to accidentally comment the randomness out of the Linux kernel CSPRNG. Nobody is going to miss the logic bug that causes the Linux kernel random number generator to not even try to seed itself.
Not letting me spend my post-tax money how I see fit (which might include paying for an open source developer who makes a tool I love's inherently expensive medical care) is bad, too.

And stuff like charities to help certain classes of people (poor kids who would benefit from a $300-5000 operation once, like Watsi, seems like a better use of charity money than an 80 year old guy living one extra day) seem like absolute good, too.
That's because exceptions aren't supposed to be 'handled'. Usually you only catch an exception while you do some cleanup, maybe print some information from it, assuming you even know what you caught, then rethrow.
I did field work in Panama and Ecuador at the same time/place as one of the authors of this paper (Roland Kays; he's also the first person to cross the isthmus of Panama on a unicycle). The field work required to find and observe olingos and olinguitos is pretty hairy. They are nocturnal and arboreal. You can radio track them, but first you have to find them and catch them. Not an easy thing to do in the understory at night.
ok, so you guys track the clickstream & optimize for clicks that don't help the user. At a per site level i can see where the bottlenecks come in, but business must be good if those are your problems. Congrats!
I'm not sure if your second paragraph necessarily leads from your first one.

I have two questions for you that you should think about.

Question 1: Why is it that, as our productivity increases, we find more things to "fill up" our workday, instead of working fewer hours for the same output (which would satisfy our needs)?

Question 2: Forget about need. Do people actually want the things they are working for today? Or is it that we are socially conditioning them, from the moment they are born, that a consumption-based lifestyle is one they need to strive for?
>But the question is, if you are doing something and the alternative is starvation and death, are you really a free human being? If you think about it for a while, the answer becomes clear: you are not free.

Thomas Jefferson would have agreed with you. His idea of America was the idea that there would be many small farms where people could be more or less self-sufficient and work would have instrinsic meaning. Of course, he had actual chattel slaves to help out. Hamilton had the idea that the US would become a trading nation. By their time, the industrial-capitalist revolution had not really gotten underway world-wide but the Hamiltonians won out in the end. The notion of 'work' as we know it now had also not really come into existence. Most people in the US worked on farms or otherwise for themselves.
Copyright Troll Ran Pirate Bay Honeypot, Comcast Confirms
>current operations rely on technology that cannot quickly determine whether a foreign mobile phone has entered the United States

If only this kind of communication could have a known location, like say, its origin tower. Maybe I completely misunderstand the phone protocols, but I thought origin tower was hard to miss.
A new, better, richer, open-souce Flash or Silverlight? Well, it could have some uses.

But in my opinion the browser will eventually simply become the OS: you will compile everything to Javascript (or at least asm.js) and use all the interesting APIs from there. Sad but very probable.
After you go into the BIOS using Win8, you should be able to disable fast boot, secure boot, change between BIOS and UEFI boot modes etc.
You might enjoy a stochastic noise machine I made:

https://sourceforge.net/projects/applpi
you'd think they'd at least disallow three-digit area codes.
The pay gap is probably because you did not pass the bar at the same "level" you were at in your old company, meaning Amazon was bringing you in at a demotion essentially.
Yahoo [inexplicably tries to] bring back the toolbar
Its generally the opposite, the phone interviews are the sanity check.
Maybe poor choice in words, but the point is no one asset can be counted on to directly monitor inflation.

Using the gold example- suppose industrial demand for gold to fuel the semiconductor industry tripled the price of gold compared to 1969. Now suppose the price of milk, bread, gasoline, electricity, water, clothing, and alcohol only doubled in price compared to 1969. If inflation is a measure of your purchasing power IN GENERAL (not your purchasing power of gold), inflation was roughly 200%, no?

If gold had absolutely no practical value by itself, it would be free of market demands like that in my example. But of course then its value would have no connection to purchasing power, and we're right back where we started.
I'm pretty sure it is assumed you've paid off your house as part of this plan, and housing is by far the main distinguishing factor in cost of living between different cities. So I don't think location would matter quite as much as you're making it seem.

If we assume that the $25k is net, not gross, then I can see how it could be reasonably comfortable for one person with no rent or mortgage. You'd really want to go to a place with cheap property taxes to minimize unavoidable recurring housing costs. But anyway, you'd have roughly $2k to spend each month, which seems like it could comfortably cover utilities, food, transportation, and some entertainment, even in a non-shitty place. Keep in mind you wouldn't have to save money because you're retired--this is supposed to be solid and stable revenue for the remainder of your life (but only time will tell if that holds true).

Of course, throw in other people to support on that income, like kids, and it definitely gets tighter, but I don't think this number is at all unreasonable for a single person supporting only themselves with no debt and complete ownership of a home.
Do you happen to know, which is `destructuring-bind`, destructuring or pattern matching?
....and most people don't care with what the NSA is doing so let's move on with this NSA thingy and submit more interesting technology news so that we all can be happy, no?
When you say 'work' you have to be be explicit in what you mean. Do you mean 'work' as it has come to mean in the industrial capitalist revolution way? Or the kind of 'work' that, say, a forager/gather type society would do? It could mean effort towards creating something new and neat, like music or story telling.

The reason I ask is because without distinctions, it is difficult to tell what your motivations are and what about what kind of work you find attractive.

As a side note, the word 'work' of the industrial revolution sense being combined with notions that it automatically makes you better than people who don't 'work' in the same sense because it makes them more childish was one of those 'white-man's burden' type justifications for imperialism because of that particular poem's observation that non-european first nation people were 'half-devil and half-child'.

NOT an accusation of you. Just an observation. :) This is and, will be, a contentious topic in the near future, I think.
Stop making cows. Quit being calves. (Feb 2012)
shenanigans. Pyramids (at least in js) can be easily avoided by simply naming your functions. Treating them like the first class objects they are. Naming the function means you are no longer going to an arbitrary code block, but instead going to a concept whose name, doc string, and (through hoisting) position on the page illuminate its purpose.

Callbacks aren't bad. Pyramids are bad. Stop writing pyramids.

Nodejs also establishes a nice api for callback functions-- in particular, callbacks are defined with an `error` and a `data` argument. You handle the error if it is non-null, otherwise execute `data`.

If you want to avoid callbacks, Node also provides event emitters, and streams. Streams in particular provide a nice api for dealing with event based programming.
you might find Moldbug interesting then.

moldbuggery.blogspot.in
even the art assets are named the same -- not to mention the html structure, etc.
I think you grossly misunderstood what I said.

What I meant by "subsistence living" is working enough to cover the essentials, and no more. These essentials include food, water, shelter, and healthcare.

The problem is the last one: it is astronomically expensive, which means that subsistence living still means working a ridiculous amount of hours.
Neat trick, but probably too limited to be of much use. Also, stopping it is kind of a nuisance.
>James R. Clapper Jr., the director of national intelligence, has acknowledged that the court found the NSA in breach of the Fourth Amendment, which prohibits unreasonable searches and seizures, but the Obama administration has fought a Freedom of Information lawsuit that seeks the opinion.

Are you fucking kidding me? Let's take this incident to the most die-hard scaremonger out there and ask them how the hell is it in the interest of national security to hide it when government institutions are found guilty of breaching the Constitution?
Question 1: Because people want more than they need. This is practically an axiom. You don't need much more than a pile of sticks to sleep under, food, and water, but I bet even you would agree this is not satisfying.

We aren't unique in this regard either. My cat needs air, water, and food. My cat wants attention, affection, and canned wet food.

Question 2: I wasn't socially conditioned to want the fan that keeps me cool when it is hot. I wasn't socially conditioned to enjoy beer. I wasn't socially conditioned to like literature. Sure, some people are working for things they have no real use or desire for, but IMO there are plenty of things that improve life beyond the truest basic needs, that are worth continuing to strive for. Amusement, art, intellectual pursuits, athleticism, etc...
Because it doesn't work in the government's favor and makes the deficit higher.
I like this defense.

"Your honor, I only stole 0.00000512% of this bank's money. I should get off with time served."

"Your honor, I was only distributing 0.00000125% of the city's weed. I should get off with time served."

"Your honor, I only murdered 0.000000004695% of the population of the US. You look at a number in absolute terms that looks big, and when you look at it in relative terms, it looks a little different."
this use case is inherently more complicated than any of the control flow structures you mention here. You are introducing a new closure, and you don't know when the function is going to be executed.
Aw come on. Have you ever programmed in Java? Anybody who has written any java code knows that class name is wrong.

AsynchronousBureaucraticProccessDispatcherFactoryFactoryFactoryInterfaceProvider

There I fixed it for you. And of course you have to specify the provider in the META-INF/async file.
>>Life cannot be sustained without effort.

In this day and age, sustaining life should not require 40+ hours of work per week.

As a society we are producing a ridiculous amount of surplus, and then conditioning ourselves to consume that surplus so that we can produce even more.

Where does it end?
I'm sure there are scores of [unsavvy] people that love that toolbar.
Get a life (The more you use Facebook the more miserable you are)
Not totally, the problem being described as "Callback Hell" is in my experience: non-locality of code. Things that relate to one another should be spatially together for a programmer to write, read, understand- and NOT split into success and error conditions around the axis of final callback.

Even with named functions, this is the problem- right? You pass in a named callback and you have to find that function later when you're debugging to figure out what's going on. Locality of code means no breaking context to find something not already on screen and therefore easier programming.
I'm not a beliver, so I may be missing something important...

As far as I can see, await makes it possible to do things like:

- UI Thread starts Thread X to do something slow;
- Thread X is processing, in the meantime the user clicks on something that requires X's result;
- Only now the UI thread stops, waiting for X.

Your program stay responsive, unless it's completely not able to do so.

As I said, I still don't think it's a so important feature. It is quite rare that one needs such kind of coordination in UI programs, and there are better mechanisms for no-interactive software (that optimize for throughput, not responsiveness)... As a second thought, it may be very relevant for games, I don't know.

I also don't get why the node.js people consider it so important to have concurrence at a web server. For me, it only makes sense for sites that have less concurrent requests than server cores, AKA: nobody.
Suppose you're a Foreign Terrorist. If you're planning an attack on the US, can you do it entirely from your country? At some point you have to contact some people in the US to carry out the attacks. But oh, the Americans you hired are very wily, and they know that, to be relatively anonymous and have their shenanigans hidden, they have to call from different phones, send emails from different accounts, use different identities, encrypt everything...

Mr. American Terrorist Contractor can't have all his communications tied to a single identity that could be reassembled with Big Data. So he tries to keep very few traces of his activity, and confuse snoops with false leads and dead ends.

Mr. American Terrorist Contractor called from many phones, used many addresses, etc. The dragnet to catch him must be large. It will include some innocent Americans. Tens who called a phone he called that same day. Hundreds who went to the same deli as he went last Friday. Add more situations, area codes, phone call graphs and quickly you have most Americans.

That's by design, though: you can't have surveillance that's capable of catching domestic terrorists without surveilling innocent citizens, and you can't try to end terrorism with surveillance without spying on the people who will actually perform the terrorist acts in your land.

EDIT: As it currently stands, the NSA is supposed to help end terrorism by spying on all foreigners. What I'm arguing is that surveillance of non-citizens always leads to surveillance of citizens. Some Americans are uncomfortable with the US government spying on American citizens, but comfortable with the USG spying on foreigners. They may be less comforted when they realize how, if the real intent of the surveillance is to prevent terrorism, only spying on foreigners won't help much.
Even for the Chrome: https://news.ycombinator.com/item?id=6221556
Wow. Just wow. Simply amazing you can think that given the distribution of wealth in the world. The only reason the vast majority of us have to work to eat is because the vast majority of the proceeds from our labor go to benefit a tiny global elite.

For quite a long time now, the technical means have existed to provide the basics of life to every human being on the planet at a modest cost. And yet we don't – instead the vast majority of us continue to work hard to provide that global elite their "due".

Institutionalized theft? How about economic and social justice?
Jeff Bezos gave me hope
Maybe I'm just not reading the article carefully. Or maybe these scientists are in line for a Nobel Prize for finding a "carnivore" species that "feeds on fruit". Or maybe it's just a very poorly written article.
I think the difficulty of the malloc question is a bit hard to assess for non-kernel programmers. Best I could do is some educated guesses that would probably be wrong. But then I am not a kernel/systems programmer

The LRU cache on the other hand sounds trivial.
Don't forget that the rent is too damn high. Shelter don't come cheap.
I'm genuinely curious about the motivations of some of the people that endorse me. Are they expecting me to endorse them back? Why do they keep endorsing me for things I don't really do?

You said you didn't want to write a "LinkedIn totally sucks" rant, but let's be honest, LinkedIn totally sucks.
Rust supports both manual memory management and GC.
I generally agree that there are better ways to handle asynchronous control flow than callbacks, but I think this is exaggerated. As in most posts like this, the callback soup examples are difficult to follow primarily because they are horribly written, not because of callbacks.

As long as you write decent code, the main impediment to asynchronous programming is reasoning asynchronously, not syntax. If you require complex asynchronous logic and don't use an appropriate algorithm, you'll end up in the muck whether you use callbacks or await.

Taking go as an example: while I agree that the go statement is more elegant than a callback approach, I see it as quite a minor win compared to channels. The go statement is convenient syntax, but channels are what make concurrency in go feel so robust, and it's a pattern than can be applied just as well in a language that uses callbacks.
Obama said the NSA wasn’t “actually abusing” its powers. He was wrong
If I was the interviewer I'd just check how they go about it - do they just start typing or do they read the docs, that's a big one right there. I wouldn't expect bug free code, just a reasonable attempt, clean code, and something that generally works because a LRU cache is really simple.

I disagree it's useless - if I have a senior developer, they better know how to do the basics. Otherwise what are they good for?
Code that performs simple sequential steps should be synchronous.

Keep the asynchronous complications at the code that perform non-sequential steps. And yes, I'm fully aware that some libraries (Javascript's one, the guilty are always the same few) force you to use asynchronous calls. That's a flaw of the library.