Re: Have you ever seen a room full of second graders try to log into something? - <AUTHOR>

Maybe I'm just attacking the weakest point of your argument, but I feel like this has to be pointed out.
> Step 1 is Facebook Connect for education: one identity to tie together all of a student's learning applications into a cohesive experience.
2nd graders can't use Facebook.  Facebook's TOS requires you be at least 13, due to COPPA and the personal nature of Facebook data.  The rest of your advertisement for jobs doesn't really make sense, since I don't know what problem you're solving - since the issue brought up was logging in - maybe you're just doing an education identity platform?
No idea.  Just wanted to point out that your example was flawed. <comment> jack-r-abbit For context: [https://news.ycombinator.com/item?id=7716837](https://news.ycombinator.com/item?id=7716837)

Also, how come some of these posts have no author and no way to flag or comment? (not that I want to flag or comment them... it is just odd to me.)

<comment><USER2> They're YC companies, who get to make special posts like that when hiring on HN.

<comment><USER3> One of the things I like the most about HackerNews, and I suspect many (most?) others do too, are the comments. I clicked on the original link curious about why there was not any comments or up arrows ... but will know in the future that it is a waste of time. Why don't they simply add a label like [Jobs available] to clearly identify the purpose of such links?

<comment><USER2> You can tell by the absence of links to Discuss and Flag the post. I also find these posts a bit odd but HN is YC's sandbox after all, so I can't really complain about them building their own sand castles.

</comment></comment></comment></comment><comment><USER4> I have to agree with you there, I don't believe "Facebook Connect for Education" could take off in this case because of the Facebook ToS.

<comment><USER2> I think they meant 'it' _like_ FB connect...,' or at least I hope so for the sake of their competency. I agree that the whole post was particularly poorly written.

<comment><AUTHOR> Ah you're right, on second review that is what it means. Dropping the entire product name makes it parse like you're just combining the two.

And now I feel particularly stupid.

</comment></comment></comment><comment><USER5> I thought the weakest part of their argument is that second graders have no problem logging into anything. My daughter is in second grade and her class manages just fine. They all have their own login on the school computers and no problems.</comment>


Ask HN: What is the "jquery" of PHP? - <AUTHOR> I have been using PHP for a while now, but I always did it raw - no frameworks.<p>Is there an "all purpose" PHP framework that I should know of? Kinda like jquery is a javascript simplifier in a way, that can be used for pretty much anything. <comment><USER2> I think the major php-framework is laravel: [https://laravel.com/](https://laravel.com/)</comment>


Cisco's Bold Networking Start-Up - <AUTHOR> http://bits.blogs.nytimes.com/2012/03/16/ciscos-bold-networking-startup/

<comment><AUTHOR> What I find fascinating is that this seems to be a regular facet of cisco's culture. Some employees leave _, start a start-up with access to Cisco's manufacturing/engineering resources, poach a bunch of employees from Cisco, then get bought back for huge sums of money a couple years later. As the article mentions, this must be tough on morale for the people that aren't picked to join the hot-new product-line.

_ I use the term "leave" very lightly. Apparently, Mario, Luca and Jain's previous spin-ins: Andiamo and Nuova moved right across the street into buildings still owned by Cisco.</comment>


Twitter 'alerted NBC to British journalist's critical tweets' - suspends account - <AUTHOR> http://www.independent.ie/business/technology/twitter-alerted-nbc-to-british-journalists-critical-tweets-3186360.html

<comment><USER2> This was on HN earlier, the crucial detail was that the journalist was tweeting personal information for an NBC executive (his email address) which is a violation of Twitter's policies.

<comment><USER3> No it's not, because 1) it's a corporate email address, 2) it was posted online in other locations prior to the tweet being posted, and 3) Twitter states on their website: _"If information was previously posted or displayed elsewhere on the Internet prior to being put on Twitter, it is not a violation of this policy."_

</comment></comment><comment><USER4> It is purely logical that Twitter act within the best interest of its commercial partners, personally I'm not sure how this is newsworthy.

<comment><AUTHOR> by that logic if the Syrian govt were to sponsor twitter they should suspend all accounts that criticize them?

I think if there was no email address in the tweets and the journalist had his account suspended then this would be very newsworthy.

At the moment at least twitter have a leg (albeit shaky one) to stand on.</comment></comment>


Identify the niche influencers for your market using Google data studio - <AUTHOR> https://www.agrigoryan.me/post/identify-niche-influencers-with-google-data-studio <comment><USER2> very interesting, thanks! Been trying to connect the Twitter connector but for some reason, I get: "Sign in with Google temporarily disabled for this app". btw, I don't agree influencers' marketing is a great tactic (at least for a startup), but that's for a different discussion.

<comment><AUTHOR> would love to have a discussion on that! I'm thinking that each of us can be an influencer in one way or another, and word of mouth is in its own way an influencer marketing too.

<comment><USER2> In that sense I agree, we can all be influencers, but that's more like a referral program and not an influencer imho. I wrote about my experience here, I think it sums up my view [https://www.polidoesntcare.com/blog/thoughts-on- influencers-...](https://www.polidoesntcare.com/blog/thoughts-on-influencers- marketing) However, I do have some ideas on how to make it more efficient with ecommerce</comment></comment></comment>


How To Wake Up Early and Feel Refreshed Without Sleeping More - <AUTHOR> http://dalethoughts.com/2012/02/how-to-wake-up-early-and-feel-refreshed-without-sleeping-more/

<comment><USER2> Biggest thing for me: sleep with ear plugs. 6 hours of sleep with them, and I'll feel more rested than 9 hours of sleep without.

<comment><AUTHOR> Any particular ear plugs you use? I find many earplugs to be uncomfortable.</comment></comment>


Vacationing in a Police State - <AUTHOR> https://medium.com/@safari_poet/vacationing-in-a-police-state-bde34a35f55f#.p5h4e1bd9 <comment><USER2> ...I thought it was going to be an article on England.</comment>


Action Potential Mechanism - <AUTHOR> https://ocw.mit.edu/high-school/biology/exam-prep/structure-and-function-of-plants-and-animals/response-to-the-environment/action-potential-mechanism/ <comment><AUTHOR> Fascinating explanation of neurons by Prof. Eric Lander, part of OpenCourseWare published Introduction to Biology [https://ocw.mit.edu/courses/biology/7-012-introduction-to- bi...](https://ocw.mit.edu/courses/biology/7-012-introduction-to-biology- fall-2004/)</comment>


Macy's banned from detaining and fining alleged shoplifters, judge rules - <AUTHOR> https://www.theguardian.com/business/2016/jul/01/macys-shoplifting-detention-fines-lawsuit-ruling <comment><USER2> _" Moftah, 53, was carrying two bags – one from JC Penney, and the second from a previous Macy's shopping trip. Her plan was to exchange clothes from a couple of weeks prior for different sizes. After finding clothes for her daughter, she went to a register to buy and exchange the other items.

On the way out, a Macy's Herald Square manager pulled Moftah aside by the arm, and told her that she needed to accompany her to an office, and that she had shoplifted, according to an affidavit provided by Moftah's attorneys from the Usar Law Group. She thought she would show the manager her receipts and be on her way, and followed her into an elevator with her purchases. Two plainclothes security officers joined them on another floor. In the basement of Macy's they led her to a row of "what looked like jail cells". Moftah's purse and phone were taken, and she was patted down under her shirt, legs, private areas as she repeatedly asked what was happening.

According to the affidavit, one of the employees said, "see what's under the scarf" in referral to her hijab. She repeatedly mentioned that there was a huge mistake, and they should check her receipts. Moftah was locked in one of the cells. Her things were reviewed in front of her, and she "continued to plead with her (the manager), telling her "these were mine, and I had purchased them on my Macy's card," and she could easily verify this.

The manager approached her with documents, and told her to sign them repeatedly and pay $100 in order to go home. Moftah hadn't eaten all day – it was Ramadan. When she began to cry, she was threatened with handcuffs and taunted for stealing during Ramadan and being Muslim, according to her affidavit. The Macy's manager returned and told her the new price to go home would be $500. When she refused to do so, her credit card was removed from her wallet and charged for the full amount."_

I'm usually all in favor of catching/punishing shoplifters, but the above is just shocking. I don't know what the appropriate solution is, but giving a bunch of store-employees the power to run their own mini-jail, lock up anyone they feel like locking up, and preventing them from contacting anyone else for help... that sounds more like the plot of a Stephen King horror book, not a democracy.

<comment><USER3> The minute they try to lock you in a room the only appropriate response is to Bobby Hill your way out of there.

<comment><USER4> Try to lock you in a room? You've already let them go to far. They try to physically stop you at the door, just keep walking. If it escalates from there, quickly consult local laws and your attorney for acceptable responses.

</comment></comment></comment><comment><USER5> Good. They are not the police. They are not a jail. They are not allowed to arrest people. This is the worst kind of vigilante "justice" I've ever seen.

I mean for chrissake they took her phone, belongings, and credit card (!) and charged her for a random amount. This is beyond ridiculous.

<comment><USER6> Felony kidnapping, felony wire fraud come to mine.

</comment></comment><comment><USER7> Macy's deserves to get sued, and the people directly involved should be charged with false imprisonment. This is totally ridiculous. Almost like corporate vigilante justice, but since corporations aren't people, it's really just wrong.</comment>


Why Is Python Growing So Quickly? - <AUTHOR> https://stackoverflow.blog/2017/09/14/python-growing-quickly/ <comment><USER2> > Why Is Python Growing So Quickly?

Really easy to answer: It is stupid fun to program with Python. There are libraries for everything you can imagine and they are generally very easy to use. Once you grok the virtual environment thing, writing apps/programs/scripts is just a matter of creating a new env and installing the libs you need. Testing ideas with Jupyter notebook is fun, fast and rewarding. Pycharm is awesome. VSCode with Python just works. You can automate tons of boring stuff (Thanks Al!)... and the list goes on... and on...

<comment><USER3> I have come to the conclusion that part of the reason python is so fun is because it is slow.

There are so many lovely and easy to use libraries in Python. I took a couple and tried to be inspired by them to write a C++ library, maybe for addition to boost.

However, if you are writing C++, people expect your library to be fast and memory efficient -- you can't go around sticking the entirety of a parsed file in a std::string. Also, people then start saying your code better interoperate with their templated classes well, and they want to replace the memory management entirely, and it goes on...

Of course, the resulting libraries are very fast and very clever, but they have lost the joy. They also take much longer to write, maintain and use.

<comment><USER4> One of my clients recently replaced a major chunk of their C++ code with Python and achieved a speedup from multi-hour to sub-millisecond. That's a big win.

Python encourages readable code, which enables smarter algorithms, which ultimately swamps all those little memory optimizations. Oh, and PyPy/Numba/Cython let you get those little optimizations, too.

<comment><USER5> > One of my clients recently replaced a major chunk of their C++ code with > Python and achieved a speedup from multi-hour to sub-millisecond.

I'd _really_ like to know what they were doing and how they could do it so wrong that the C++ version took hours while the Python version was faster than a blink of the eye.

<comment><USER6> Good question. I did have a situation where looping over a fairly large Pandas dataframe took 12 minutes, but using the underlying numpy values took only 3 seconds. The looping was required to do complicated row and column operations.

Similarly, naybe the C++ code was using an inefficient data structure for a large dataset compared to using something like Numpy.

</comment></comment></comment></comment></comment><comment><USER7> Mostly because the whole Data Science and ML stuff is catching on. Everyone and their grandma now wants to do something related to AI, ML etc. The easiest language for these is? Python. Hence the growth.

Once upon a time it was all about cloud, SaaS and building a webapp. Hence the growth of JS.

<comment><USER8> The chart makes a pretty compelling case that this is the right answer. The top trending libraries are pandas, numpy, and matplotlib (both flask and django are probably trending at the same baseline rate of any top 10 popular language). These are all libraries heavily used in data science.

We also know that ML and AI are new macro trends in the tech industry. Python's elegant syntax isn't really evidence for why Python is trending _now_ as opposed to any other time in the last decade.

<comment><USER9> > These are all libraries heavily used in data science.

These are all libraries heavily used in any technical computing field. The cost of MATLAB, the simplicity of Jupyter, and the community around Python have caused Python to slowly be a language used for general technical computing, not just data science.

</comment></comment></comment><comment><USER10> I don't like how Numpy, Matplotlib and Pandas are portrayed as "Data Science". There is nothing particular to "Data" in these three packages. All I see is "Science".

All scientists need numerical simulations or evaluations, plotting, and statistics. That's what these libraries do. Not "Data Science", but "Science".

The correlation with TensorFlow/Keras suggests Data Science, maybe. But I bet there is a similar correlation with scikit-learn, Scipy, scikit-image, basemap, and heck, Matlab, Julia and R--and those each suggest different scientific endevours.

TL;DR: In my opinion, Python is becoming the language of _Science_ , which includes, but is not limited to, _Data_ Science.

<comment><USER11> I'm still at a loss as to what type of science there is that doesn't have data.

"Data science" to me seems like a buzzword that has connotations of a field or industry starting to use science where they previously didn't. Over here in academia it's just "science", or possibly "data analysis" if you want to emphasise that that's the part of your project you're working on right now as opposed to data collection.

<comment><USER4> Theoretical physicists don't always use data. Many scientists sometimes use case studies instead of systematic data collection.

<comment><USER11> Eh. Case studies is still data. And the theoretical physicists that don't use data are criticised as not really doing science. Most theorists I know (I am in physics) are heavily data-driven.

</comment></comment></comment></comment><comment><USER12> Python has a reputation for being a good "beginner" or "scripting" language. Describing it as such is really a disservice.

One of things that makes Python a killer language (apart from its readable syntax and straightforward programming model) is how it enables you to jump in at any skill level and be immediately productive, without hampering your ability to get things done quickly and elegantly as your skills grow.

There are faster, trendier languages out there, but I suspect Python will still be thriving when many of them have become footnotes.

<comment><USER13> This has been such a frustration of mine when mentoring people through learning to code.

Python is a great beginner language, but it isn't a language that is only for beginners.

</comment></comment><comment><USER14> Python is what BASIC was in the 1970s and 80s, in a good way.

It enables people that normally would not program to do things that they otherwise could not be done with traditional software with a GUI, that being web based, apps or desktop applications.

It is a stepping stone into computing that otherwise would have been inaccessible for many. Unlike BASIC, the design of the language is good enough that it can be used in professional applications, and not only being a stepping stone.

</comment><comment><USER15> because readability is one of the most, if not the most, important quality for mainstream programming language adoption.

<comment><USER16> But significant whitespace means that I can't write code like this:

       sub (@) { return map { "@{[ $_[0] . $_ ]}" } @$_ };

Disclaimer: The majority of the programmers that I have known in real life that have a significant (and _very_ vocal) dislike of Python's whitespace requirements have all written code like that above (this is my from-memory reproduction of actual code that one of them wrote). Python sucks because it's "restricting" them from being "expressive" with their code.

<comment><USER17> What does that do?

<comment><USER18> So let's break it down:

        sub

It's an anonymous sub

        (@)

It has a prototype that says it accepts a list of arguments (this is the default in perl though).

Prototypes are mostly for giving hints to the compiler on how to unambiguously parse calls to your function later. For an anonymous sub, it's pointless because you assign its value to a variable, and then brackets are required when calling it.

        return

It returns the result of the map (this default in perl is to return the result of the last expression & everything is an expression though)

        map

same as python map(code, list)

        { "@{[ <some stuff> ]}" }

This is a particular perl goof for interpolating array lookups into a string. Usually, perl's sigils let variables be interpolated without any issue, but since we're using $_[0] to use the first element of the @_ array, it's ambiguous with $_ . '[0]'.

The @{} dereferences the contents of the braces as an array, and [] creates a new arrayref. The arrayref has one element, and perl's default stringification of an array (join them all with no separator) means that it… iterpolates the thing inside the @{[]} into the surrounding string.

This is pointless though, since it's the only thing in the string. The author might have been trying to give a string context to force stringification of the thing, but the dot operator already provides that context.

        $_[0] . $_

This is a string of the first element of … hmm. Not of the currently-mapped element (that's $_). $_[0] refers to the first element of @_. This makes a new value which is the concatenation of the first element with the current element.

        @$_

This is a short way of writing @{ $_ }: dereference the arrayref that's stored in $_. But $_ is not set anywhere, so I assume this is a typo of @_

I would have written this as:

        my $prefixer = sub { my($prefix , @rest) = @_; return map { $prefix.$_ } @_ };

And it would work like this:

        say $prefixer->('Hi_', 1, 'str', 7);
        > 'Hi_Hi_Hi_1Hi_strHi_7'

The 'best' way to write it would have been:

        sub { $_[0].join($_[0], @_) }

<comment><USER18> The python equivalent is

        lambda *lst: ''.join([str(lst[0]), str(lst[0]).join([str(_) for _ in lst])])

Which is uh… begging for an initial line of "lst = map(str, lst)"

<comment><USER19> If I follow correctly, the equivalent in K would be

        {,/(*t),/:t:$x}

Flatten (,/) the first element of the list (*t) joined with each element of the list (a,/:b), where t is the input x cast to a list of strings (t:$x). Curly braces make the expression an anonymous function, and since no argument names are specified explicitly the name x is the single input argument.

</comment></comment></comment></comment></comment></comment><comment><USER20> _based on Stack Overflow question visits_

Is Python use really growing? Or is this a Stack Overflow thing? I thought it was being displaced by Javascript Everywhere.

Python had a 5-year setback from the Python 3 transition, but we're now mostly past that.

<comment><USER21> Well, most devs I know would rather use python for server-side and scripting, but you're not wrong. Python never found a way to do cross platform UI as well as react native; it's on every browser; you don't have to unlearn brace syntax.

That said; the idea of something like numpy in javascript is years off and laughable.

</comment></comment><comment><USER22> Really simple answer...

University undergraduate classes in a variety of courses use it as their default language, so it is a bunch of students trying to complete their homework assignments.

</comment><comment><USER23> OK Stackoverflow, that's enough charticles about this language or that, and which one's growing and which one gets used by whom at what time of day and in relation to which other query etc. It's like they didn't expect the attention they got for these, and now they're addicted to it. Nothing against Python... because if anything my underlying point might be that language doesn't ultimately matter that much.

But besides, there still remains the same question as always: Doesn't the posing of Stackoverflow questions tend to reflect more who's _starting_ to use a language, than the sum total of who uses it per se? (Since presumably questions taper off with time.) If you're measuring growth or adoption, as in this case, sure, it might seem like a reasonable approximation, but it doesn't tell you anything about long-term use (by people who become experts and stop visiting Stackoverflow) or about attrition (people who quit using it and move on to something else). Thus any trend Stackoverflow can see, probably overemphasizes short-term phenomena. Which is great if you're doing algorithmic trading on the stock market and make your money by responding to the market's every short-term boom & bust (and other investors' overconfidence & diaper-crappings respectively), but not so great if you're choosing a language to which you'll devote months of study.

</comment><comment><USER24> Python is a great language, despite its quirks. Imagine how popular Python would be if it had decent basic documentation and a single active version? The confusion caused by Python 3 caused at least a decade of slow adoption and the docs, well, that's pretty much a lost cause. (Compare [https://docs.python.org/3/library/os.path.html](https://docs.python.org/3/library/os.path.html) to [https://nodejs.org/api/path.html](https://nodejs.org/api/path.html) \- the latter has a nice summary at the beginning, an index of methods at the top of the page listing everything below, method inputs and return values are noted for each method clearly, concise non-interactive terminal examples that you can copy/paste for each method is given, the exact version the method was added, a collapsed history of changes and any error types thrown. My only assumption is that the Python maintainers must have a side deal with O'Reilly to keep the docs in the worst format ever as a source of continued revenue for both.)

<comment><USER25> I'd say that, over the last twenty years, Python's docs have gone from excellent to good to middling to excellent to good to middling (dropping as the language expanded and the generally expected standard went up, and improving when they did one major revamp).

So I agree that another revamp would be good now, but I historically the docs have been a plus as much as they've been a minus, relative to Python's alternatives.

<comment><USER26> Much plain reference data is missing from the docs (like return types). Its neat to describe a function, but if you don't hand out the API, then the docs are not all that useful.

</comment></comment></comment><comment><USER27> Many have listed out the technical reasons, but I think there's a cultural aspect: I think many people are turned off by the community of languages like Ruby. Sometimes you just want a great tool, not unicorns and kittens.

<comment><USER28> What exactly are you talking about here?

Are you referring to Github, Shopify, Basecamp and many other functional businesses scaled and built on the shoulders of ruby "unicorns" and "kittens" ?

Having worked with both languages, I can confirm that they simply have different view points with tradeoffs, and that in itself is a matter of personal opinion.

But claiming one community does not build great tools because you view them as "kittens" is ridiculous.

Also please do not generalize things like "most people" prefer X.

[EDIT] I sincerely hope this comment does not come off as rude. I am just trying to understand OP's point of view

<comment><USER29> I think he means those intro to ruby tutorials where they make ruby (and programming in general) sound all magical, where it's so easy to program and programming is just unicorns and kittens or whatever. It becomes tiring and dumb after a while.

<comment><USER29> Add in ducks and geese and a whole slew of other animals and I end up wondering if I'm programming in a zoo with ruby lol.

</comment></comment></comment></comment><comment><USER30> The most interesting part of the post is the conclusion where the author says that he's a data scientist who uses R and doesn't feel the need to switch to Python!

He also has very good thoughts, and very important for beginners to know, about how there isn't a single right way to learn programming.

> In any case, data science is an exciting and growing field, and there's > plenty of room for multiple languages to thrive. My main conclusion is to > encourage developers early in their career to consider building skills in > data science. We've seen here that it's among the fastest-growing components > of the software development ecosystem, and one that's become relevant across > many industries.

<comment><USER31> How it that interesting? Statisticians and economists everywhere use R instead of Python

<comment><USER30> The fact that the author wrote a sizable post about how big Python is and is growing, but then says he's more of an R type of person instead of Python. Obviously that's interesting to see when authors aren't giant fans of what they're trying to promote.

</comment></comment></comment><comment><USER32> My simple answer to this, apart from the arguments laid down in the article, is that the Python core devs (and community) have found a unique balance between sobriety and adventurousness. I think this explains why the language was adopted by data scientists and ML researchers. My complaints with other languages usually center around them being too preoccupied with theoretical or academic concerns (e.g. Haskell) _or_ being too loose in adopting new features or opaque syntax (e.g. Javascript).

Also, Python is probably the most concise and easy-to-read imperative language that has gained wide acceptance.

</comment><comment><USER33> Besides the obvious answer: pseudocode alike, also don't forget: worse is better.

Of all major languages is by far the slowest, hardest to extend and by now easily surpassed PHP and JavaScript with its number of design quirks.

</comment><comment><USER34> I don't think SO questions is the best way to gauge the popularity of a language and especially not a package.

I big reason why Pandas is so popular is because its API is so complicated. I probably have 10x more experience using Pandas than Django. And yet, when I'm doing something in Pandas I'm visiting the documentation far more often than Django. Let's compare the top level APIs:

>>> import pandas as pd

>>> len(dir(pd))

177

>>> import django

>>> len(dir(django))

11

Also, I find the data manipulation Pandas provides is far inferior to the R Hadleyverse and is one of the few things that R does better than Python.

<comment><USER26> Django has a very deep package tree, there are tons of stuff in there — a lot of things you wouldn't expect.

<comment><USER35> Django admin could fill a section by itself.

</comment></comment></comment><comment><USER36> Because programming in Python is great for productivity, has lots of useful libraries, is rather bearable/enjoyable depending on your view point and for 90% of people/companies you don't need the speed of anything more than PyPy or Cython because, believe me, you're not at Facebook or Google scale, and even those companies often use Python (Google most famously).

Btw, for those of you who dislike the dynamic typing (e.g. myself) of Python, check out Cython, it's really heaven.

</comment><comment><USER37> I'm a Python answerer on Stack Overflow, I teach Python at NYU, and whaddaya know, I write Python for my day job.

Why is it growing so quickly? I speculate:

Lots of people want to learn to program - and Python is easy to learn and teach.

I think it blows other languages out of the water. I'm going to compare it to its closest competitor, Ruby. Ruby is also open-source, high level, popular relative to other languages (which means you can probably get help if you need it), it has lots of libraries (meaning you can do a lot with it), ok tutorials, and a decent package manager. On the downside, Ruby is also a very large language, which makes it much harder to learn to mastery.

I think Python blows Ruby out of the water in terms of how easy Python is to learn relative to Ruby.

I don't encourage people to learn Ruby. I spent a long time (months) trying to learn it. I still don't tell people I know it.

I used to think that Ruby's syntax is twice as much to learn - now I think it might be even more than that.

Ruby's YACC file is ~918 lines long[0], while Python's grammar file is 149 lines long.

        ~$ wc cpython/Grammar/Grammar
         149  879 6472 cpython/Grammar/Grammar

Even if 1/2 of Ruby's grammar output is whitespace, that's more than twice as much grammar to learn as Python's grammar[1].

I could compare Python to other languages, but I don't think they come close to matching the upsides of Python.

I still want to learn other languages, like Haskell, lisps, and C, to a level of mastery - but since I can be so productive so fast with Python, the other goals are something I work on in my spare time without a bunch of urgency.

[0] [https://stackoverflow.com/a/16629318/541136](https://stackoverflow.com/a/16629318/541136)

[1] [https://docs.python.org/3/reference/grammar.html](https://docs.python.org/3/reference/grammar.html)

PS I can see that this comparison to Ruby isn't popular due to the downvoting - but nobody is contradicting my point.

<comment><USER38> _Cough_. Python's _cpython /Grammar/Grammar_ uses a compact EBNF notation. Converted to yacc it is about 850 lines long.

</comment></comment><comment><USER39> Now that powerful machines are commonplace, the biggest limiting factor of software creation is developer productivity.

Python's so popular because it maximizes developer productivity.

</comment><comment><USER40> I say all the following as an avowed Rubyist

1) Computational Linguistics libraries

2) Machine Learning libraries

3) Still one of the blessed languages internal to Google? and BFDL was employed for a while there

4) Jupyter Notebooks

5) Coder Dojo approved language

I used to think that all dynamic languages (Ruby/Python/Javascript/Perl/…) were of a par but I have to admit that Python has an awful lot of mindshare and it's beginning to exhibit strong network effects.

<comment><USER41> >I used to think that all dynamic languages (Ruby/Python/Javascript/Perl/…) were of a par but I have to admit that Python has an awful lot of mindshare and it's beginning to exhibit strong network effects.

Ruby is a wonderful language with a really unfortunate standard implementation. It's easily 5 times slower than Node at practically anything, which is sad because Ruby is infinitely better than Javascript. I really think this is what it comes down to and why Rails has been dying off.

<comment><USER40> All that beautiful meta-programming flexibility has come at a price. The research projects sponsored by the likes of IBM and Oracle to give Ruby a much needed speed boost are very slow in the offing – it feels like V8 was developed overnight in comparison. Aesthetically I think Ruby beats Python/Javascript/Perl but unfortunately that's not enough to move the needle on the dial.

It'll be interesting to see whether Python or Ruby or Ruby get to WebAssembly first – I'm correct in saying that none has of yet, yes?

<comment><USER6> Common Lisp found a way to be performant. Is Ruby really that much harder to optimize than other dynamic languages? JS had the advantage that there was strong incentive to make it fast in the browser, and V8 had Lars Bak working on it.

<comment><USER40> Apologies to everyone for turning this into a Ruby thing on a Python topic.

You can check out the Oracle Labs code and progress of Graal/TruffleRuby here: [https://github.com/graalvm/truffleruby](https://github.com/graalvm/truffleruby)

Relevant page: [https://labs.oracle.com/pls/apex/f?p=labs:49:::::P49_PROJECT...](https://labs.oracle.com/pls/apex/f?p=labs:49:::::P49_PROJECT_ID:130)

And IBM's Ruby+OMR code and progress is here: [https://github.com/rubyomr- preview/ruby](https://github.com/rubyomr-preview/ruby)

Relevant post: [https://developer.ibm.com/open/2017/03/01/ruby-omr-jit- compi...](https://developer.ibm.com/open/2017/03/01/ruby-omr-jit-compiler- whats-next/)

Can Matz somehow in the nicest possible way kidnap Lars Bak and pay him in gummy bears or something?

</comment></comment></comment></comment></comment><comment><USER42> I have mostly left Python and moved to R, Racket and Lua for my needs. It is hard to see how Python won't stay the predominant first language for decades to come just due to momentum and the good reputation.

My first language was Basic and my second language was C64 Assembly and Pascal. I would have killed for Python as a kid.

</comment><comment><USER43> It's the libraries I think. that's why I started using it. I don't think it's particularly different syntactically from most other languages. The built in data types are nice, though why they insist on using different names from other languages (lists, dictionaries ...)

Better editors help too.

<comment><USER44> I may be biased, but I much prefer "dictionary" to "hash table" and "list" to "array." They provide much better metaphors to real-life things, instead of requiring people to learn and use additional jargon.

</comment></comment><comment><USER45> It's dead simple and people complain about speed but I use it for massive distributed backends handling hundreds of messages each second and scaling without problem.

And this was way back when twisted was the only asynchronous game in town. So I'm not surprised it's growing.

</comment><comment><USER46> How do people create and manage internal python packages that work together as an ensemble? I've found the packaging system with setup.py dependency_links to be pretty cumbersome and not well supported. How do people version these internal packages and manage them? Running your own pypi seems nontrivial and using github eggs/releases isn't very functional either.

My experience with python has been positive but I don't understand how people who want to create separate libraries for specific functionality tie these codebases together without using deprecated features or containerizing everything.

<comment><USER47> Gemfury provide a service which might be useful.

If you need to keep things on premise, is running your own pypi particularly hard? I've never tried so maybe there's a bunch of hidden complexity but there are some packages to run one and even a docker image: [https://hub.docker.com/r/codekoala/pypi/builds/bwe6cdn4swgyi...](https://hub.docker.com/r/codekoala/pypi/builds/bwe6cdn4swgyiruoolkpqp/)

</comment></comment><comment><USER48> The obvious answer to me is the slow trickle down of people from universities as CS programs have migrated from Java/Scheme to Python. This also overlaps with Stack Overflow usage, so I think that explains a lot.

</comment><comment><USER49> Python has been continuously becoming the entry point of computer programming. I think the language reached that goal and now people who started with python are contributing in different fields.

Personally I met with python thanks to course assignments. It helped me to finish my projects way faster than any other language. I loved its simplicity and now even in my complex projects, I tend to solve my problems in "python way".

Also modularity, almost non-existent boiler-plate code, etc kind of things attract data scientists without computer science background.

</comment><comment><USER50> #1 - it comes installed on most Linux and on Mac (even though different versions can be a bit of a pain sometimes)

#2 - it's dead simple to do things; the syntax is, to me at least, about as direct and uncomplicated as you can get (and without being overly wordy!)

#3 - so many handy libraries... it's good for full projects, and it's great for integrating and gluing things together

I wouldn't call programming in Python fun, per se, but I do call "getting things done quickly and easily" fun.

</comment><comment><USER51> It's not only because of data science of machine learning. Big, high profile projects are being done in Python (eg. Openstack).

I am at a big company, and it seems most new projects are being done in Python. No one asks why, it is just accepted.

Now the question is why. I have no explanation, other than maybe that's because universities have been teaching python more often, and it happens to be practical.

I just wish everyone were using Python 3.

</comment><comment><USER52> As someone introduced to Python and C two semesters ago, I'm not surprised at all. If I want to be really nerdy and crank some performance, I write C. If I want to test ideas, write to a text file, or basically anything else, I use Python. Python just makes it all super easy and nice. I _respect_ the performance gains of C, but ease of use will always win.

</comment><comment><USER53> I've started to use python a lot for 3d scripting on Blender and Maya. On Blender this is the only option.

</comment><comment><USER54> Python has been in the top 3 of hiring posts within "Who is hiring" threads for at least 4 years now[1] so interesting to see other datasets noting Python's popularity as well.

1\. [https://hntrends.com](https://hntrends.com)

</comment><comment><USER55> Why is Python So Aggravating?

That's a question that bugs me. I can't believe the level of obviousness of the things that are wrong. That is because we write complex code. Things like direct access to data members (which is 'pythonic'!) are cruel blows to software productivity for complex code. Ugh, Ugh, let me count the ways: No compiler to check the code. The other day I dumped 800 extra lines into a file as a typo. Many, many duplicate functions. Of our whole test suite, how many tests failed? One!!! Ugh. This is not even to mention the topics of Black.Holes.In.Your.Code because you can't tell what types the functions receive. I really think python is driven by non-programmers who consume rather than produce complex code and the teachers who teach these people. I believe the problems will increase over time. Does anyone know the story of Hack at Facebook? I heard the lead developer give a talk once. Be afraid.

<comment><USER56> Keep in mind that there's python development practices which might be adequate to solve your problems.

> Things like direct access to data members

I think you're complaining about (lack-of-) encapsulation. Between methods, functions, and properties, there's ample opportunity for encapsulation. The convention is for internal-use-only members to be prefixed with an underscore.

> No compiler to check the code.

In fact there are many static checkers. pylint, pyflakes, etc.

> This is not even to mention the topics of Black.Holes.In.Your.Code because > you can't tell what types the functions receive.

In fact, you can use type hints [1] to do this.

> The other day I dumped 800 extra lines into a file as a typo. Many, many > duplicate functions. Of our whole test suite, how many tests failed? One!!! > Ugh.

This isn't quite explicit enough for me to understand. You unintentionally redefined a function multiple times in the same file, and your test suite caught the error. You think that instead Python should've refused to execute/import this module w/redefined functions? Hmm, I suppose it's a very uncommon need to redefine functions but it's not uncommon to assign a function to a file-scope name. Also keep in mind that both pylint and pyflakes detect this mistake.

[1] [https://docs.python.org/3/library/typing.html](https://docs.python.org/3/library/typing.html)

<comment><USER26> > I'm not sure that you've taken the time to understand python development > practices.

I think this tone is misplaced here.

<comment><USER56> I think you are inferring more tone than was intended but I will edit it because it could be considered rude.

</comment></comment></comment></comment><comment><USER57> Because it's easy for people to learn with no prior knowledge in programming. It's taught in many intro classes now and as time goes on the simple fact will cause the language to be used more in production environments as well.

</comment><comment><USER58> Easy package management. If Java made it just as easy to add packages, and run in an interpreted mode, it might have had similar success. Actually years ago there was something called "jython"

</comment><comment><USER59> Is stack overflow traffic a good indicator of library growth? It seems like libraries with really good documentation would require fewer stack overflow questions regardless of their popularity.

</comment><comment><USER60> Related discussion of the previous post: [https://news.ycombinator.com/item?id=15186025](https://news.ycombinator.com/item?id=15186025)

</comment><comment><USER61> Heh, most of the questions I've answered are in the Flask and/or Vue tags; not surprised to see them related and I'm happy that python's popularity keeps on growing.

</comment><comment><USER62> The really interesting question though is how big of an influence meta-posts like this one has on the growth of one programming language over another. How would you model that?

<comment> mark-r Have you ever known someone to pick a language based on a blog post?

<comment><USER62> Javascript programmers base a lot of their choice of framework on where the hypetrain is heading, which blog posts can have a lot of influence over.

</comment></comment></comment><comment><USER17> TL;DR, machine learning.

<comment><USER6> ML plus Pandas, Matplotlib, SciPy, Jupyter Notebooks, etc.

</comment></comment><comment><USER63> the colleges and programming intro courses for my university are starting off with python now. When I went to uni it was a language called processing which is a simple version of Java. College started out with JavaScript moving into .Net. Some my teacher I kept in contact with moved over the courses to python which might also be a factor in python popularity. Not to mention High schools programming classes also starting with python or js instead of QBasic.

</comment><comment><USER64> It sucks less than the alternatives.

</comment><comment><USER65> The community is very welcoming, in my experience.

</comment><comment><USER66> This just about sums it up for me: [https://xkcd.com/353/](https://xkcd.com/353/)

</comment><comment><USER67> It's beyond my comprehension... it's so .. ugly .. and dead .. and unexciting ... zzzzzzz</comment>


David Lowery is on a crusade for copyright, fairness and art - <AUTHOR> http://www.salon.com/2013/12/04/david_lowery_silicon_valley_must_be_stopped_or_creativity_will_be_destroyed/ <comment><USER2> It's a special case of a more general problem of a winner take all economy where almost all profits go to the holders of monopolies on attention and distribution channels.

</comment><comment><USER3> David Lowery is a troll.

</comment><comment><USER4> he's subsumed his identity so far into 'becoming a copyright wonk' that he can't see how people DO make it without copyrighting (and who are even more radical about it than the pirate party). Nina Paley, for example.</comment>


Dropbox dark pattern forces you to pay for a whole extra year to cancel - <AUTHOR> http://i.imgur.com/J4VtJZe.png <comment><USER2> That's not what this says.</comment>


Concurrency Models, Rust, and Servo - <AUTHOR> http://www.lars.com/concurrency/rust/servo/2013/12/21/concurrency-rust-and-servo.html

<comment><AUTHOR> For some context, the 80+ message discussion that was mentioned in the first paragraph stem from this post: [https://mail.mozilla.org/pipermail/rust- dev/2013-December/00...](https://mail.mozilla.org/pipermail/rust- dev/2013-December/007414.html)

Lars works for Mozilla on the Servo team, but has done work on the CML [1] and Manticore [2] languages, mainly in the realm of performance optimization I believe.

[1] [http://cml.cs.uchicago.edu/](http://cml.cs.uchicago.edu/)

[2] [http://manticore.cs.uchicago.edu/](http://manticore.cs.uchicago.edu/)

<comment><USER2> As bjz points out, my background is from CML, so my experience has biased me a bit towards synchronous send for same machine/process programming models and async for distributed models. But I tried to give them both a fair shake in the context of, "What implementation strategy makes Servo fast and reliable?"

</comment></comment><comment><USER3> Awesome post. All this discussion makes me realize that we haven't hit the sweet spot yet and need to keep considering more message passing use cases. I am wary though of providing too many options and very much want to have one channel type that is most useful and least error prone that we can recommend by default.

I do disagree slightly with the final conclusion that context switch on send defeats the advantage of unbounded channels since work stealing will ensure the sender runs again very soon.

</comment><comment><USER4> It's good to read an intelligent discussion of the pros and cons of synchronous and asynchronous message passing. Asynchronous is more general, but building protocols on top of it can be a real pain (i.e. implementing ACKs and so on).

Gotta say, everything I read about Rust makes me like it more.</comment>


Rockstar: A programming language where programs are also song lyrics - <AUTHOR> https://github.com/dylanbeattie/rockstar <comment><USER2> "Mainly because if we make Rockstar a real (and completely pointless) programming language, then recruiters and hiring managers won't be able to talk about 'rockstar developers' any more"

Hahahahaha I love you for this.

Easiest path to becoming a certified Rockstar developer.

This is so we'll thought out and hilarious. You've earned my number one spot for best esoteric programming language. It used to be Chef where the programs make recipes and someone made a program that output hello world but actually was real instructions for baking a cake. They then baked the cake. But this? Oh the sky is the limit with this !

<comment><USER3> The version number scheme should start from "10X" as well....

</comment></comment><comment><USER4> > But why?

> Mainly because if we make Rockstar a real (and completely pointless) > programming language, then recruiters and hiring managers won't be able to > talk about 'rockstar developers' any more.

> Also 'cos it's kinda fun and any language based on the idea of compiling > Meatloaf lyrics has to be worth a look, right?

> Also we can make stickers. Who doesn't want a sticker on their laptop saying > 'CERTIFIED ROCKSTAR DEVELOPER'?

They had me at the recruiters point. And honestly I've heard a lot worse reasons for more serious languages.

<comment><USER5> Maybe we should create more languages called Agile, Senior, Expert, Lead, Ninja, 1 Mio Dollar, Ivy League, Full Stack, etc

<comment><USER6> Full Stack, a language where the only data type is a stack.

<comment><USER7> We just need someone to make a derivative of Forth.

</comment></comment></comment></comment><comment><USER8> I created the missing interpreter!

[https://github.com/dylanbeattie/rockstar/pull/27](https://github.com/dylanbeattie/rockstar/pull/27)

It's hackish and hard to read and full of bugs, but it can run FizzBuzz, so Rockstar is a real language now. If the pull request gets accepted I'll add "certified Rockstar developer" to my CV.

<comment><USER9> consider creating separate repo? This looks real awesome. checkout JS implementation here. [https://github.com/wolfgang42/rockstar- js](https://github.com/wolfgang42/rockstar-js)

<comment><USER8> This is a very simple language and I don't intend to work on it long-time. I prefer to think of it as a donation to the language designer.

</comment></comment></comment><comment><USER10> this reminds me of when I was learning to write fortran code for the navy around 1990. My rookie debugging method was to insert print statements throughout the code, but instead of printing something informational I would put 80s song lyrics. When I ran the program (which calculated fluid flow around submarines), it would print the lyrics to a song. Wherever the song stopped was where my code was failing.

</comment><comment><USER11> Years ago I worked on an ecommerce website that followed the "idiomatic variable names" recommendation. All (I mean literally all) the variables were called things like 'gunsandroses', 'meatloaf' etc. I don't know if they did it that way in the first place for shits and giggles or if they did an obfuscation pass at the end, but I didn't find that it assisted maintainability.

<comment><USER4> At highschool went through a phase of naming them after fish. It started as a joke but quickly because an obsession. But after a few months even I found it impossible to maintain and this was just personal highschool projects. I can't imagine trying to maintain larger and more complex code bases which have been developed by a team of people.

</comment></comment><comment><USER12> Awesome! FizzBuzz example in idiomatic Rockstar from the repo:

      Midnight takes your heart and your soul
      While your heart is as high as your soul
      Put your heart without your soul into your heart

      Give back your heart

      Desire is a lovestruck ladykiller
      My world is nothing
      Fire is ice
      Hate is water
      Until my world is Desire,
      Build my world up
      If Midnight taking my world, Fire is nothing and Midnight taking my world, Hate is nothing
      Shout "FizzBuzz!"
      Take it to the top

      If Midnight taking my world, Fire is nothing
      Shout "Fizz!"
      Take it to the top

      If Midnight taking my world, Hate is nothing
      Say "Buzz!"
      Take it to the top

      Whisper my world

</comment><comment><USER13> My bittersweet tragic morning:

0) Check hacker news

1) Read about Rockstar. Get more and more excited

2) Go to download/build the interpreter/compiler/whatever

3) It's not implemented yet? I can't write Rockstar code RIGHT NOW?!

NOOOOOOOOOOOOOOOO

<comment><USER14> They're still looking for a rockstar developer to implement it ;)

</comment></comment><comment><USER15> This is epic. Time to write a hello world and update LinkedIn. "Genuine Rockstar Developer, 2018-". Please make and sell the laptop stickers. I'll buy a dozen.

</comment><comment><USER16> Sadly this isn't implemented yet; it's going to take a real _rockstar developer_ to build a formal grammar, parser and runtime (I imagine the easiest thing to do will be to map the language onto e.g. JavaScript, much like what TypeScript does).

The language has some conceptual similarities with Shakespeare, for instance; Shakespeare also has a poetic way to specify numbers based on adjectives with positive and negative sentiment. Shakespeare is fully implemented and used occasionally for comedic effect in programming contests; see [http://shakespearelang.sourceforge.net/report/shakespeare/sh...](http://shakespearelang.sourceforge.net/report/shakespeare/shakespeare.html) for a rundown of the actual language.

</comment><comment><USER17> I feel the need to arrange that fizzbuzz into an actual song.

</comment><comment><USER18> I think unit tests should be written as corresponding MIDI files: lyrics = code, music = tests.

</comment><comment><USER19> idea: a Meta language where all the keywords are read from a file (text, json etc)

So you could sub out the words and make your own style of language.

The obvious one is Ninja but you could knock out other ones as people come up with them. You could have a Halloween language etc.

Btw, instead of "continue", rockstar should use "and on and on"

<comment><USER20> I'm going to need a variation of Rockstar with more brooding darkness and satanic references for system programming.

I.e. closer to metal.

</comment></comment><comment><USER21> Here is my attempt to create (compose?) Fibonacci(25):

      Tommy was a kindle
      Jane was gasoline
      Put Tommy over Jane into the fire

      Put the fire into the daydream
      Knock the daydream down

      away takes time
      If time is nothing
      Give back time

      The nightmare was over
      Build the nightmare up
      If time is the nightmare
      Give back time

      Put time without the nightmare into my world
      Put time without the fire into yours
      Put away taking my world into the daylight
      Put away taking yours into the night
      Give back the daylight with the night

      Put the daydream into my love
      ever is so rock

      Until my love is stronger than ever
      Put away taking my love into the night
      Whisper the night
      Build my love up

</comment><comment><USER22> The sample code is kinda fun to read.

</comment><comment><USER23> It seems possible that 1980s power ballads were programs all along. I'm going to run "Mr. Crowley" as soon as these guys release a compiler.

Pretty sure a hot AI hologram will pop out of my IBM Compatible's antenna.

<comment><USER24> Why wait? You should be able to simulate one by hand in fairly short order.

<comment><USER25> But not without being a certified Rockstar dev, and they haven't printed the stickers yet.

</comment></comment></comment><comment><USER26> Now each team of rockstar developers will have to find a really good name!

</comment><comment><USER27> Ok guys, I'll write the readme, you just go and write the language.

</comment><comment><USER28> Love it. LOVE IT.

However, it's missing one tiny little bitty thing:

      goes to 11

How come _" goes to 11"_ is not a reserved sequence of keywords?

</comment><comment><USER29> Impressive error handling. I accidentally typed !love as a property and it returned back "you give !love a bad name"

</comment><comment><USER30> HAHAHAHAHA! This is funny! :D It's pure genius. And I would love to be a certified rockstar developer.

</comment><comment><USER31> Looking for Rockstar developer. Entry level position, must have 5 years experience developing in Rockstar.

</comment><comment><USER32> This is just fantastic.

</comment><comment><USER33> This is pure genious!</comment>


To plot my next murder, I went to the Body Farm - <AUTHOR> https://www.nytimes.com/2019/07/16/books/review/body-farm-lisa-gardner.html <comment><USER2> Anecdotally, my dear old Mum (now in her mid-70s) worked as a forensics investigator on the Snowtown murders (aka the "Bodies in the barrels" case) in the final stages of her career. She took some samples to the FBI in the USA as part of her work, and snagged me a cool FBI hoodie and t-shirt (well, I thought so anyway). Quite a morbid and disturbing business to be in, but I feel fortunate to have a parent is such a good role model; she completed her PhD around the age of 50, and had another whole career in scientific research and forensics after that. As I'm heading towards the same age it gives me some hope I can also make a sea-change.

I also learned, after asking some questions about the case, that sometimes you are better off being ignorant of the details. And that some people are really capable of terrible, terrible acts against others. :( Fortunately she had quite the grim sense of humour to help her deal with the cases she worked on.

<comment><USER3> _Fortunately she had quite the grim sense of humour to help her deal with the cases she worked on._

Unfortunately, even a sense of humour doesn't protect you from PTSD when dealing with this sort of stuff, particularly on a daily basis. I recently listened to the audio book version of Dr Richard Shepherd's "Unnatural Causes" [1]. It's all very fascinating, and he's clearly passionate about his work while also providing a great service to society as a whole but as becomes clear, it has also affected his mental health and family life.

[1] [https://amzn.to/2LBaOF4](https://amzn.to/2LBaOF4) \- (The audio book is excellently narrated by the author himself; that doesn't always work out well, but it does in this case.)

<comment><USER2> Thanks for the recommendation, I'll definitely grab a copy.

</comment></comment></comment><comment><USER4> Great article! I learned a lot about human decomposition, and I'm glad there's a facility out there doing this kind of research.

One nitpick: The author mentions a recent study claiming that cell phone use can cause bone spurs on an individual's head as an example of how quickly our bodies can change while we're still alive (vs what happens over generations and while decomposing):

> Changes in DNA can take generations to occur. By contrast, our skeletons can > show widespread changes in as short as 10 years — from the bony protrusions > now increasingly common on the back of our skulls ("text necks," some are > calling them) to our increasingly low bone density as we transition from > manual labor to office work.

There have been serious deficiencies identified in the original study, from not actually measuring and providing data to back up their claims, studying the wrong thing, and did not have a random, representative sample. This doesn't detract from the main point of the article, but goes to show how easily an inaccurate study can permeate the societal knowledge without being corrected.

[https://www.pbs.org/newshour/science/smartphones-arent- makin...](https://www.pbs.org/newshour/science/smartphones-arent-making- millennials-grow-horns-heres-how-to-spot-a-bad-study)

[https://www.nbcnews.com/health/health-news/questions- raised-...](https://www.nbcnews.com/health/health-news/questions-raised-about- study-linking-phones-bone-spurs-skull-n1021706)

</comment><comment><USER5> I recently read _A Dog 's heart_, by Mikhail Bulgakov. There is a part where he describes the operation on the dog. When I read that part, i told myself there is absolutely no way he could come up with such a vivid description if he had never operated on a live body.

Turns out, the author had been a doctor in world war 2 and had witnessed some terrible things. And they made their way into the book.

<comment><USER6> His semi-autobiographical A Country Doctor's Notebook is well worth a read.

Also it was WWI not two.

<comment><USER7> The Netflix series based on it with Daniel Radcliffe as the doctor was a joy to watch.

</comment></comment></comment><comment><USER8> I always pretend this body farm doesn't exist. I think the research is very important, but I don't like knowing it is a few miles from my office!

I'm a professor at UTK, where the farm is located.

<comment><USER9> Yeah, when the zombie apocalypse starts you're in a bad spot.

</comment></comment><comment><USER10> For anyone who liked this article, I can recommend Mary Roach's "Stiff: The Curious Lives of Human Cadavers" (2003) [1]. A fantastic book about what happens to human bodies after death. Part of the book is about visiting a body farm. She's a funny, very talented writer.

[1] [https://www.goodreads.com/book/show/32145.Stiff](https://www.goodreads.com/book/show/32145.Stiff)

</comment><comment><USER11> This is interesting stuff, for sure.

But a key word doesn't appear in TFA: "motive".

No matter how well you hide/burn/dissolve/etc the remains of anyone with whom you have a relationship, you'll be a suspect. You can try to fake an alibi, and obscuring the time of death does help with that. However, any evidence for that having been done may implicate those with motives, because a random serial killer likely wouldn't bother.

That's why most unsolved murders involve ~random selection of victims.

<comment><USER12> Only 60% of murders in the US are solved. The police are not as diligent as you'd think.

[https://www.vox.com/2018/9/24/17896034/murder-crime- clearanc...](https://www.vox.com/2018/9/24/17896034/murder-crime-clearance- fbi-report)

<comment><USER11> Sure. But what's the murder clearance rate among general HN readers? I bet that it's substantially greater than 60%. As either victim or killer.

</comment></comment></comment><comment><USER13> That's a well-placed cliffhanger at the end

<comment><USER14> it's weird, it's almost advertisement for murderers to buy the book...

<comment><USER15> So you just have to track who bought the book (eg. ask Amazon) to find potential suspects!

It reminds of [https://www.marianne.net/societe/attentat-colis-piege- lyon-a...](https://www.marianne.net/societe/attentat-colis-piege-lyon-amazon) : someone built a bomb using Amazon Basics batteries and acetone bought on Amazon

</comment></comment></comment><comment><USER16> Quote: "I finally hit on a possible scenario during my last afternoon. I ran my idea by Jantz. She told me she thought it was deeply disturbing but also brutally effective. I went home and got to work."

Yeah, everybody whom watched Breaking Bad knows it too. It involves 2 barrels of plastic and acid.

<comment><USER17> Who watched, not whom watched. "Whom" is only applicable for the object of a clause.

<comment><USER18> Completely unrelated, but I only recently learned and became comfortable with this distinction (despite somehow intuiting it in my use of the word) after getting further in my German and French classes. We seem to do a poor job of actually teaching English grammar in this country, and then we stumble upon these rules when learning _other_ languages!

<comment><USER17> I only really learned English grammar properly when I studied Latin in high school.

</comment></comment></comment></comment><comment><USER19> You're right about the need for hard evidence to back up unsubstantiated medical claims. Sometimes crooked doctors actually make fake diagnoses of bone spurs as favors to their draft-dodging patients.

[https://eu.usatoday.com/story/news/politics/onpolitics/2018/...](https://eu.usatoday.com/story/news/politics/onpolitics/2018/12/27/trump- vietnam-war-bone-spur-diagnosis/2420475002/)

<comment><USER20> We detached this subthread from [https://news.ycombinator.com/item?id=20490344](https://news.ycombinator.com/item?id=20490344) and marked it off-topic.</comment></comment>


Race conditions on the web - <AUTHOR> https://www.josipfranjkovic.com/blog/race-conditions-on-web <comment><USER2> I was once involved in helping diagnose a race condition in a website whereby a user could change another user's password if they changed their password at approximately the same time. When looking at the code it was not at all obvious that there was even potential for the issue until you knew it was going on...

Some on this thread are acting like these are trivial problems to avoid. I think they are wrong...

<comment><USER3> How's that work when you set passwords according to id?

<comment><USER4> Yeah, this is my question exactly. I've dealt with MANY race conditions over the years and the idea that two different user requests could update the same user account password seems... unlikely at best. Not saying it's impossible, but more detail would have been appreciated.

<comment><USER5> I've seen this before in a Java system. A MVC Controller populated the HTTP params into a Bean, which it assigned to an instance field, and then used that subsequently to grab the value to update (don't think it was password, might have been email address iirc). This would work fine if the controlled was request scoped, but it turned out to be a singleton - so the field was shared across all requests!

</comment></comment></comment></comment><comment><USER6> It always amazes me when developers making crucial transaction systems don't know about or implement some form of locking. I personally use a cluster of consul servers for distributed locking ( [http://consul.io](http://consul.io) by hashicorp ) although I don't use the rest of consuls features I'd sure like to learn how someday :)

<comment><USER7> You can build what you think is the most robust and secure system in the world, someone somewhere will figure out how to break it. I don't think it's fair to insinuate that the people who wrote the code were "incompetent", especially given the size of Facebook's codebase. And given their audience they'll be more exposed to hackers than whatever thing you'r working on that isn't Facebook and doesn't have the same audience.

<comment><USER8> Exactly. When I write my code I am aware of a high number of things that could go wrong, and that I deliberately don't check. If it goes wrong I'll let it crash, or I make the deliberate decision too see if that condition ever actually happens in the real world. I'm not talking about security! It can be things like only checking if function parameters are what I expect them to be for _some_ functions where I think it's important, or being aware that if some functions are called with other timings than I expect something could happen. The problem is I'm not writing the final app, I'm writing some sort of library (sort of), so I have no control over how it is going to be called in the end. I'll just add it to the documentation but I make few attempts at catching all or even a lot of such errors.

If I would blow up my code at least tenfold if I tried to take care of all the possible conditions - creating a lot more of them in the process. Writing code feels amazingly fragile to me, and yet it works well. Note that that code has had several reviews from other developers, so I'm not talking about really bad code.

After having delved deep into medical topics out of curiosity - hundreds of hours of anatomy, physiology, neuroscience, bio-chemistry, lots of statistics, I'm even less concerned. The ways things go wrong in a biological system are orders of magnitude more numerous, and the approach of nature is "fix it when it happens" (or start by creating a new instance).

I think the more complex our own human-made systems become we'll have to use more and more of the nature method. We are already doing it everywhere, electronics or software.

I see two competing forces:

a) The human attempt to make systems more "provable", for example by formalization/"mathematization",

b) Nature showing us that complex systems can only be done with a relaxed and laissez-faire attitude ("shit happens") after putting in a reasonable effort.

The balance shifts towards b) for systems in rapidly changing environments, and to a) for systems in static conditions.

So discussions about the subject should never be just about the system (piece of software) itself, it _must_ include the environment it is to operate in.

</comment></comment></comment><comment><USER9> I would love to hear how these were all patched. Wrap everything in a transaction? Use some kind of MQ? Make sure these critical DB calls are not cached in any way? I'm sure it's different for each case.

<comment><USER10> Having patched one of this researchers race conditions, while I was at lastpass, I did exactly that.

This only applies to coupon redemption

<comment><USER11> Which one?

</comment></comment></comment><comment><USER12> I used to use a camera shopping website that had a race condition in their product listing/search functionality. Their site was quite slow, and if you tried to have more than one tab open to their site then you would get mixed-up results. The tabs might have the same content, mixed content (eg the breadcrumbs from the other tab), or sometimes nothing at all. This would occur even across a significant period of time, not just if you made the requests at the same time.

I struggle to understand how that could even have happened. Were they storing the results of the DB lookup referenced against my IP somehow?

<comment><USER13> I'm guessing a lot of them stem from using session variables and from caching. I've seen everything from an nHibernate cache being stored in the session, serializing and deserializing a huge chunk of the database on every request, to developers not being aware that the session variable they get is user specific (They access it via Session[UserId]).

Caching in particular seems to be something that's applied without much analysis, I've seen it slow down implementations more often than it sped them up.

What I'd really like is for the browser to send a tab id on every request, so we can scope variable to a tab as well as user.

<comment><USER14> FYI: one place to store a tab id is in the window.name variable:

* it is persistent across refreshes

* it remains even if you leave page to another domain then return to page on same tab

* it disappears if the tab is closed

* it doesn't change as you navigate back/forward

* would be most useful with xhr requests or a hidden field in form post requests.

Downsides:

* no origin security

* no obvious nice way to use with page GETs for server to know which tab a page request is from.

<comment><USER15> SessionStorage has all of those properties:

[https://developer.mozilla.org/en/docs/Web/API/Window/session...](https://developer.mozilla.org/en/docs/Web/API/Window/sessionStorage)

localStorage is often used for it's persistance across closing/reopening the browser, but for times when you don't want storage to bleed across tabs or closing the browser then session storage is much better, and unlike a cookie doesn't automatically get attached to request so there aren't XSRF worries.

(You still need to be careful of XSS of course.)

</comment></comment></comment></comment><comment><USER16> Off topic: FarmVille on a satellite connection could let you plant fields on top of each other even though they weren't supposed to intersect. Unintentional vertical farming.

</comment><comment><USER17> Bug bounty programs are interesting. I wonder if it wouldn't be a good use of tax payer dollars to pay people at the nsa or similar organization with computer security responsibilities to churn away at these programs. As in "spend one month a year doing big bounty programs, collect your normal salary, keep whatever you earn" ...

</comment><comment><USER7> Interesting, it would be even more interesting to know how these problems were patched on Facebook's side.</comment>


Can You Survive a Benevolent Dictatorship? (Doctorow on the iPad) - <AUTHOR> http://www.publishersweekly.com/article/456751-Can_You_Survive_a_Benevolent_Dictatorship_.php

<comment><USER2> Some very good points, like how Apple's i<whatever> ecosystem is more closed than TV (which allowed the advent of cable, VCRs and the Apple II), making that common dismissive comparison to the iPad a bit bogus.

On the other hand, this is one of the weakest arguments I've seen against the DMCA's protections of DRM:

" _What's more, you can invent cool new things to do with your dishwasher. For example, you can cook salmon in it without needing permission from the manufacturer (check out the_ Surreal Gourmet _for how). And you can even sell your dishwasher salmon recipe without violating some obscure law that lets dishwasher manufacturers dictate how you can use your machine._ "

<comment><USER3> Isn't that a fair reference to how for example you can't sell a device or software application that will rip your DVDs to watch on, e.g., your iPad?

There's various devices that'll import your CDs and then provide digital music throughout your home but on the Mac you need to download two different open source programs from Europe (both fighting for the title of the worst UI on Mac OS X) before you can get a digital copy of your DVDs.

A couple of manufacturers have gone to court over this and been slapped down due to the DMCA.

<comment><USER2> Oh, it's certainly fair and accurate, but ... _cooking salmon in your dishwasher???_

For it to be a _strong_ argument it needs to be something the audience can identify with, and I doubt there's much overlap between the readers of _Publisher's Weekly_ and _Surreal Gourmet_.</comment></comment></comment>