skysight-inc/HackerNews huggingface dataset:
Testing performance by iterating over an array can be dangerous because all the data is conveniently grouped together such that the processor will have the next data it needs in cache once it's loaded the first item (most of the time; when it crosses cache lines it'll cause another miss, then a bunch more hits). This can lead to huge performance boosts, but rarely reflects how data is laid out in memory unless you're very lucky.

The change made was to still iterate over a slice (i.e. an array), but the array now contains pointers to structs, which are allocated separately. This should scatter them across memory such that each step of the iteration needs to choice a different pointer to a different chunk of memory. This is a benchmarking issue which has bitten me in the past, so I made at least a feeble attempt to account for it.

However, I actually don't know enough about Go's memory allocation to really make sure I could force the conditions I wanted, so it's still possible all the data was lined up nicely, but just spread a bit farther apart. (In fact, this may even be likely since the allocation approach was very simple. Trying to do a lot of allocations and deallocations and filling in the data over a longer period would probably do a better job of addressing this concern.)
You likely can't find any narrative writing because I don't publicize it. It's at stories.wegnerdesign.com . However, the same principles apply to my tech blog. I spend a lot of time on those posts, and I don't want anyone else to have rights to it.

As far as the worth of exclusive rights, I suppose it is personal opinion, but I still disagree. Especially when exclusive rights are so easy to come by.
You don't give up every right or even any right. You retain all your rights. But you have to give medium (or google or whomever) a license to redistribute what you wrote, otherwise they cannot do so and it's pointless to have written it using that service.
I'd love for you to expand on this. Truthfully I am not an expert on copyright law, but I do find many ToS to be fairly self explanatory.

I'd be happy to update the post if I was misleading somewhere.
So the rest of the above comment where it was explained that the whole issue is actually kind of nuanced, has important security implications when it comes to implementation details and is not at all "intentionally compromising", you just skipped over that hey?
I mentioned this pitfall, but didn't show how to solve it. I haven't seen a complete example yet and didn't take the time to work out the details yet. I'm less concerned about complexity in the iterator implementation, but handling this correctly also seemed to require changing the caller code since it needs to send something on the fail channel. Then the onus is on the caller to remember to do so, which is just as bad as having to remember not to call break.

Of course, whether this is a real issue or not also depends on whether you're writing internal or external APIs. There are lots of other ways to generate uncollectible garbage too...
Cache coherence is when data that you need close in time is physically close in memory, and therefore loading the first piece of data loads the second into cache so that it will be quick to load. The performance difference between fetching from CPU cache and main memory is about a factor of 10, so this is a significant effect.

When you're writing performance critical code this is a good thing to have happen, and it can be worth a lot of effort to make sure that you benefit as often as possible. However general purpose code usually does not wind up with data that is optimally organized in memory. But in a benchmark the usage patterns are simple enough that it is trivial to get well-organized data in memory without even intending to. Whether this is likely to be predictive of real world performance depends on how carefully coded the real world program is.
Github's indemnity clause is at least as scary as Medium's licensing clause.

Any company that relies on user generated content needs users to agree to what Medium's legalese says. At least it's explicit. Assuming you own the copyright to content you put on Medium, how else can they publish it? Github's language is informal, and not written in terms of copyright, but is functionally the same ... though the full term isn't included in the parent:

> We claim no intellectual property rights over the material you provide to the Service. Your profile and materials uploaded remain yours. However, by setting your pages to be viewed publicly, you agree to allow others to view your Content. By setting your repositories to be viewed publicly, you agree to allow others to view and fork your repositories.
But why do we have to give them that right to redistribute? Using github, or even better your own server, the service doesn't gain any right to redistribute my content.
This is what Trade Joe's says, but our experience is that the bill is higher at TJ's than at, say, Walmart or Safeway, for the same shopping list.
I think that's "ADH", not "aDH":

$ openssl ciphers -v aDH
Error in cipher list
140473872484008:error:1410D0B9:SSL routines:SSL_CTX_set_cipher_list:no cipher match:ssl_lib.c:1314:

$ openssl ciphers -v ADH
ADH-AES256-GCM-SHA384 TLSv1.2 Kx=DH Au=None Enc=AESGCM(256) Mac=AEAD
ADH-AES256-SHA256 TLSv1.2 Kx=DH Au=None Enc=AES(256) Mac=SHA256
ADH-AES256-SHA SSLv3 Kx=DH Au=None Enc=AES(256) Mac=SHA1
ADH-CAMELLIA256-SHA SSLv3 Kx=DH Au=None Enc=Camellia(256) Mac=SHA1
ADH-DES-CBC3-SHA SSLv3 Kx=DH Au=None Enc=3DES(168) Mac=SHA1
ADH-AES128-GCM-SHA256 TLSv1.2 Kx=DH Au=None Enc=AESGCM(128) Mac=AEAD
ADH-AES128-SHA256 TLSv1.2 Kx=DH Au=None Enc=AES(128) Mac=SHA256
ADH-AES128-SHA SSLv3 Kx=DH Au=None Enc=AES(128) Mac=SHA1
ADH-SEED-SHA SSLv3 Kx=DH Au=None Enc=SEED(128) Mac=SHA1
ADH-CAMELLIA128-SHA SSLv3 Kx=DH Au=None Enc=Camellia(128) Mac=SHA1
ADH-RC4-MD5 SSLv3 Kx=DH Au=None Enc=RC4(128) Mac=MD5
ADH-DES-CBC-SHA SSLv3 Kx=DH Au=None Enc=DES(56) Mac=SHA1
EXP-ADH-DES-CBC-SHA SSLv3 Kx=DH(512) Au=None Enc=DES(40) Mac=SHA1 export
EXP-ADH-RC4-MD5 SSLv3 Kx=DH(512) Au=None Enc=RC4(40) Mac=MD5 export

Also note:

$ openssl ciphers -v ADH|wc -l
14
$ openssl ciphers -v DH|wc -l
38
Medium needs a license to your content to publish it. That clause grants them that license. Non-exclusive means they're not asking you for ownership, they're just asking for a license that allows them to distribute the content.

If they wanted ownership, they'd do something like Craigslist:

> You automatically grant and assign to CL, and you represent and warrant that you have the right to grant and assign to CL, a perpetual, irrevocable, unlimited, fully paid, fully sub-licensable (through multiple tiers), worldwide license to copy, perform, display, distribute, prepare derivative works from (including, without limitation, incorporating into other works) and otherwise use any content that you post. You also expressly grant and assign to CL all rights and causes of action to prohibit and enforce against any unauthorized copying, performance, display, distribution, use or exploitation of, or creation of derivative works from, any content that you post (including but not limited to any unauthorized downloading, extraction, harvesting, collection or aggregation of content that you post).
> Explicit iterators are really only noise for the "natural" iterator, i.e. in order iteration over an array.

Not really, they are really noise in a lot of situations. Right now, I can only think of one case where they are necessary: lazy traversal. Either the collection is huge or each element is expensive to materialize, so you want to do that one at a time. Iterators are perfect for this.

They are unnecessary in all other cases. For example, for your (key, value) example:

for (Entry<String, String> entry: map.entrySet()) { ... }

Go exposes too many implementation details to my taste.
Globally speaking, there is less poverty and warfare than there has ever been in human history, or to put it another way, humanity is more prosperous and peaceful than it's ever been. By all objective measures except environmentally, 2013 is shaping up to be the greatest year in human history. Really, the greatest issue facing humanity today is climate change, not the other stuff you mention.

So take some cheer in that, I guess.
PerlMotion - Perl For iOS
Because Medium is, by definition, redistributing your content every time someone loads up the article. They just distributed the parent article to me. If they sold the company, the acquirer also needs to distribute the content (transferable).

Github's terms grant them the same ability, just not as explicitly.
I can't speak for the author of the parent post, but my understanding from his comment is:

He's suggesting the development of software to help people track their mental health, in much the same way people currently track other aspects of their day to day life, such as with a fitbit or mapmyrun.
If people could track their mood, medications their taking, when and how frequently they take them, etc, that information would be valuable at both an individual and aggregate level.
Allowing people to view my content is much different from giving a company the rights to redistribute it. Github's terms may be less formal, but they say very different things.
This may be true but one presumes that NSA employees should be first of all public employees and only after all that should they be cryptographers.

A soldier is literally speaking a professional killer but a killer who's focus is very limited and specific. It's natural for soldiers to talk about adversaries. We should still be very worried if soldiers start thinking about American civilians as adversaries.
Serving your content up to readers is redistributing it. You are implicitly granting Github that right by agreeing to let them serve your content to other users.

Note that Github isn't in the user generated content business, primarily, so they are less at risk by leaving the terms loose and human. I would generally prefer Medium's terms, but written / translated into non-legalese. Some company did this a few years ago, I wish I could find it.
Sure, it's a term of art for spies. That they're using it to apply to us is the problem.

Again, it's "the most natural word" because they are spying on and actively sabotaging us, our products, and our security.
Seriously? Using a green thread is a pattern for iteration over an array? Or that creating a new function object per iteration is efficient? The "patterns" 2 & 3 listed in the article are grossly inefficient to be considered suitable to implement fixed or dynamic iterators.
Which are all Linux distros, of course.

If we are talking about the Linux kernel, specifically, then of course it's not consumer bullshit, because the Linux kernel is a technical product in a B2B market. You might as well say that Intel CPUs or Samsung flash chips or Nikon steppers are not consumer bullshit.
"Allowing people to view my content" is redistribution. There's a copy at Medium and there's a copy on the reader's computer.
Why hardware development is hard: Verilog is weird
This was my first reaction. It's disconcerting to see in a nontechnical document, but for all that these leaks disturb me, "adversary" amounts to no more than "the people who might be trying to find out what you're doing."
Well, I can log in again, but my IP address is still banned, so I don't know what to think. I'm very sorry about the whole thing.
http://www.zerohedge.com/news/2013-09-02/fiction-fact-or-sca...
Sometimes raw performance is not really called for. A lot of programmers are looking for ways to, for example, iterate over lots of different kinds of things that all provide the interface to do so, regardless of their actual types or the details of their allocation.

Sure, if you're about to iterate over a terabyte of double-precision height map data or something like that, please use an array.
Why Titles Matter a Lot if You’re a Blogger
Fair enough. My day-to-day coding with Go right now involves large data sets where materializing something like that would be expensive. I'll admit my view of the issue is strongly biased by my very real need for iterators or something equivalent that can avoid that cost!
The real question is who exactly is now not the enemy as far as they are concerned?
KeePass basically only works well on Windows and you have to trust all the other implementations that make it pseudo-crossplatform.

You mention "open-source" so much one would think its a weapon.
To build on thrownaway2424's response, the point in the article was to demonstrate the pattern for building the iterator. Very simply structured data helps do that. In reality you'd probably be iterating over a more complicated data structure, usually where the iteration requires knowledge of the data structure that should be considered private to the implementation.
It doesn't matter what the NSA does or has done with its capabilities. The NSA could be whiter than white, and but still be unsupportable and reprehensible, simply for building out the capabilities.

The vast majority of human history shows the powerful controlling the weak, usually through "legitimate" rule of convenient laws. Democracy, which inverts this with varying levels of effectiveness (the rich can still mostly buy their laws), is an aberration. But what the NSA has built is a turnkey system for an effective subversion of democracy: a database that can find anyone's dirty secrets, or, if necessary, plant the right kind of evidence.

It doesn't matter what the NSA has done so far. Sooner or later, someone with evil intent will use it. It's too much power, too centralized, too hidden, too tantalizing, for it not to be used.

And what is it all being built for? Stuff that is less risky than you getting in your car. There is zero existential threat to the USA from terrorism. It's not a credible excuse given the danger.
Is it possible you're misunderstanding exclusive / non-exclusive rights? Non-exclusive is better for you. Terms that required exclusive rights would restrict you from "licensing" your content to someone else, or even publishing it on your own.

http://en.wikipedia.org/wiki/Exclusive_right
The strings and documentation don't make it too easy to distinguish, but the docs do explicitly distinguish between aDH and ADH. I think "DH" includes any and every cipher that might use DH, but there's a good chance that for a cipher string like TLS_DH_DSS_WITH_AES_256_GCM_SHA384, which uses "DH", it's actually part of the "aDH" umbrella (certificate carries DH keys). (Credit to the original author of the article for spotting that one via RFC5246.)
I don't blame the NSA for this, their rationale is "lets collect as much as possible and then see, gathering intel is in our mission...". After all it's all legal as far as they are concerned.

I don't even blame the Exec branch that much since they have a LE mentality of "if you have nothing to hide...protect lives...blah blah"

I do however blame the courts, they could've stopped or at least not-rubber stamped this. The judges also have lifetime appointments, yet they let this happen. And no, the Congress cannot order the courts to ignore the Bill of Rights, regardless of what any legislation says.
I was read on to COI BULLRUN in 2011, AMA
Before I left NSA I was cleared for access to COI BULLRUN. AMA relating to BULLRUN / SSL / encryption / e.t.c.
> as is typically the case for electronics

How the heck did we get to a point where stuff that's largely made in China is cheaper in the US?

Is that the USD privilegue or what is it? Not only does the US get to print their way to prosperity courtesy of world reserve currency status, it seems (anecdotally) anything from gadgets to clothes is cheaper in the US than the rest-of-world.

I mean, no envy, it's just utterly fascinating and somewhat baffling.
Name some of them.
Why Atiku Should Be the Next President, By Youth Leader, Articles | THISDAY LIVE
> I think its reasonable that as a US citizen you're okay with the NSA being able to break crypto.

Because the world is divided to US citizens or the bad guys? C'mon, there is a non-US world out there, who are not bad guys, but who've just lost every respect for the US tech sector.
Cool! You can mail me at sillysaurus2@gmail

What sort of projects are you interested in?
It's pretty funny that Kandel would ever receive this critique. If you've read any of his work he is relentless at proving causation. His Nobel was earned through painstaking elimination of alternate possible methods for the formation of memory.

His genius is in seeing that A. Predictive power is scientific understanding and B. You can never be to thorough in understanding the chain of events between an event and its predicted outcome.

I highly recommend "In Search of Memory" as a wonderful autobiography, an inspirational demonstration of how science should be done, and a deep but accessible education in basic neuroscience. One of the best and most important books I've ever read.
Use "defer close(ch)". If there is a break or a panic, the channel will be closed.
I think the marginal benefit of a second BS-level degree is small given the cost in time and money.

If you're going back to school then you should definitely consider an MS. Maybe you're worried that you wouldn't be accepted or that it would be too challenging? In that case, narrow down a list of universities/departments where you would like to enroll, and identify what you need to study in order to get accepted.

Alternatively, teach yourself, and try to join a top tech company that focus on making the kind of software you're interested in. Working with great programmers has a large impact on your learning. Perhaps you're underestimating this impact because your first job wasn't challenging enough.
Please enlighten me on why he is worse?
That's what JSON is for:

{timestamp: xyz,
tz: "America/Los_Angeles"}
There is no privacy, Control your Internet face
Homeopaths and faith healers say exactly the same thing. Personal anecdotes are not data.

Most mental health disorders are inherently self-limiting and will disappear without any treatment, which makes psychiatry look far more effective than it really is. If you're depressed, you're statistically likely to not be depressed in six months time, regardless of whether you seek treatment or not. In these circumstances, it's easy for a completely ineffective treatment to look like a miracle cure. The key outcome measures for most psychiatric drug trials are episode duration and likelihood of relapse, which speaks volumes.
upvoted for the Dostoevsky reference
Because Medium just redistributed your post to us. If you use your own server then you're the one that's doing the redistributing.

If they didn't have the right to redistribute, you could sue them for letting us read your essay complaining about them asking for the right to redistribute.
IPsec is complex, so complex that it doesn't work properly. Go in shop, by 10 different firewalls, and then try to cross connect those using IPsec. I'm sure you're going to have fun time. After you manage to get the SAs connected, you'll find out that those tunnels work unreliably, connecting, disconnecting, state machine & key renegotiation totally broken etc. If it's not crap on paper, at least it is in reality. I've been using IPsec with over 50 different devices and I find it to be real pain point. Some devices do not offer all options in UI, but still have hidden values for those built in, which you don't know and need to figure out by trian and error. Devices like ZyWALL (Zyxel) and WatchGuard, StoneGate (Stonesoft) etc, have constant probelms with IPsec.
If you want real challenge, things get much worse if you're using aggressive mode and dynamic IPs with DDNS etc. Then it's total disaster, even many firewalls from same manufacturer won't work properly.
I just now have two ZyWALL USG 1000 boxes, that can't maintain reliable IPsec main mode tunnel between those, even if there's no network issues. There's simply something wrong with the software.
Old whines: http://www.dslreports.com/forum/r25350958-Zywall-35-vs-USG-1...
About null cipher downgrade attacks, simply don't allow "multiple proposals", then what's specified has to be exact match. (Or in some cases, there' list of options, which means that any option like null sipher isn't allowed.)
You could eat 2100 calories a day without gaining weight if you expended 2100 calories a day on average.

Weight training does not necessarily burn a lot of calories, particularly fat calories. It primarily depletes glycogen reserves, which are quickly replenished in 1-2 meals and a good night's rest.

There is good evidence that people who seem "naturally thin" actually burn a lot more energy throughout the day by moving in small, maybe unconscious ways:

http://www.ncbi.nlm.nih.gov/pubmed/18223609

This is the concept behind products like the FitBit, which attempts to show people the totality of their activity throughout the day.
Constructing a new world
If the unnecessary complexity has resulted in most implementations being broken then I'd be okay with calling it fundamentally broken, but I have no idea if that's actually the case.
If I were the NSA, I'd definitively try to run a service (or two) like random.org. It'll probably be cheaper than my tor exit nodes, and mixmaster remailers...
If you declare war on an abstract concept, it shouldn't surprise you when your people start looking for tangible targets that fit the abstract concept, even if most of your soldiers are home.
Not a meta-analysis, but this 76 year study of 268 male Harvard students: http://www.theatlantic.com/magazine/archive/2009/06/what-mak... is more illuminating than much of the pop-psych literature on "happiness" that I've come across.
NSA Can Spy on Smart Phone Data
Was that the fault of the unions or the companies employing them? Seems like the bulk have been companies underfunding their obligations.

This particular trait was often coupled with many municipalities, including most of the state of California, agreeing to pension obligations that made little sense during fat times and were worse when things started tanking.
Iterator callbacks, generators, or functors feel very un-Go-like. It's trying to force a Python or OCaml idiom on to Go. Basically, what you want is to implement a HasNext and a Next function and write a "for" loop. All you need is this:

for ; iter.HasNext(); val = iter.Next() {
// do stuff
}

There's no reason to look down on the humble for loop. Complexity is a bad thing, usually.

Channels and goroutines are also a very Go-like way to process data. But APIs that return channels assume that the caller wants concurrency, so be sure that that's true.
Without such advice, that article is dangerous. A "lot of programmers" are going to read that and assume these patterns differ between them only in terms of "performance" which equates to "ns/op".

Also, I wouldn't use an array to iterate over a terabyte of double-precision height map -- have you tried that? I have, kind of. In a genome sequence visualization application. Try it sometime. It's fun.
He brought up another point. Given the known NSA revelations so far, it seems ignorant at best to welcome people who have ties with the NSA without putting their opinions under some scrutiny.
What you said makes no sense. The assumption is that a block cipher is secure to differential cryptanalysis. CBC mode requires unpredictable IV, and as the BEAST attack shows, chaining is a bad idea. RFC 3602 specifies using a random IV. Could you please cite minutes and an RFC, and maybe some more information so we can judge for ourselves?
Plus, when you have an NSA asset in the place of "heda of security" at facebook... why would you think he were not doing things at facebook that made FB "compliant" with the way NSA wants them to be. I.E.: adopting the "known good" security appliances/policies/companies...