Literate programming: presenting code in human order - <AUTHOR> http://www.johndcook.com/blog/2016/07/06/literate-programming-presenting-code-in-human-order/#.V32uxZvDTmQ.hackernews <comment><USER2> Peter Norvig's comment hits the nail on the head for me:

" Peter Norvig 6 July 2016 at 11:47 I think the problem with Literate Programming is that assumes there is a single best order of presentation of the explanation. I agree that the order imposed by the compiler is not always best, but different readers have different purposes. You don't read documentation like a novel, cover to cover. You read the parts that you need for the task(s) you want to do now. What would be ideal is a tool to help construct such paths for each reader, just-in-time; not a tool that makes the author choose a single pth for all readers."

Has anyone attempted something like this?

I've heard you can do transclusion in org-mode which might be a starting point

Edit: Some initial ideas:

\- Code can be deconstructed into blocks, and where the code is not self- documenting, prose can be added. Or even visualisations etc if a block is conceptually tricky to grok. You could even have MOOC-style validations to verify reader understanding for each block.

\- Some kind of topology of the blocks should be generated based on how they interact and how they are conceptually related

\- The author creates a few 'starting points' for different audiences, e.g. 'if you've used X before, start at Y'

\- From there next blocks to read are auto-suggested to the user. A map or network diagram of all blocks is also provided so the reader can chart their progress and see where the 'big ideas' lie.

Edit 2: This also really reminds me of Bret Victor's 'Humane Representation of Thought' lecture ([https://vimeo.com/115154289](https://vimeo.com/115154289), 45:40) where he says there is a conflict between code being an engineering specification and an authored work meant to be read by humans.

<comment><USER3> I don't understand why there not being a _single_ best order of presentation for explanation is grounds to dismiss the whole endeavour. I bet that there are many _pretty good_ orders for humans that are an improvement over the order the compiler wants the stuff in. Besides, the compiler doesn't demand a single best order, most programs could be re-ordered in a number of ways acceptable to the compiler (my point being that this criticism seems to hold literate programming to a standard that the incumbent of compiler-required ordering is not held to.)

Edit: added the parenthetical comment

<comment><USER2> Yeah I agree. What I would imagine a tool like this would do is help to find and navigate the pretty good order(s) whether they have been hand crafted at first by the author or not.

A comparison would be how desire paths form and are often turned into real paths.

I like your parenthetical observation too!

<comment><USER3> There was an interview with Guy Steele in the book _Coders at Work_ , and in one bit he had something to say about actually referring to the (literate) source code for TeX [1]:

 _Sometimes I 've got a specific goal because I'm trying to solve a problem. There have been exactly two times, I think, that I was not able to fix a bug in my TeX macros by reading_ The TeXbook _and it was necessary to go ahead and read_ TeX: The Program _to find out exactly how a feature worked. In each case I was able to find my answer in 15 minutes because_ TeX: The Program _is so well documented and cross-referenced. That, in itself, is an eye-opener--the fact that a program can be so organized and so documented, so indexed, that you can find something quickly._

 _The other thing I learned from it is how a master programmer organizes data structures, how he organizes the code so as to make it easier to read. Knuth carefully laid out_ TeX: The Program _so you could almost read it as a novel or something. You could read it in a linear pass. You 'd probably want to do some jumping back and forth as you encountered various things. Of course, it was an enormous amount of work on his part, which is why very few programs have been done that way._

[1] link to the page (337) in Google Books [https://books.google.ca/books?id=2kMIqdfyT8kC&pg=PA337](https://books.google.ca/books?id=2kMIqdfyT8kC&pg=PA337)

<comment><USER2> That's a great anecdote and makes we want to read TeX: The Program.

I really think there's something in the 'jumping back and forth' of the reader that could be leveraged, like if there was a way of recording, distributing, aggregating, analysing it etc.

<comment><USER3> It doesn't add that much to the above, but the now defunct Bookpool had a column where they asked various authors for lists of their favourite 10 computer books, and they asked Guy Steele [1]. His first entry was:

 _Computers & Typesetting, Volumes A-E Boxed Set by Donald E. Knuth -- I'll read anything that Don Knuth writes, and he has written quite a bit, including Surreal Numbers and 3:16 Bible Texts Illuminated as well as the famous Art of Computer Programming series. But this five-volume set is my favorite. The two volumes titled (and sold separately) as The TeXbook and The METAFONT book are well-known, but what I really recommend to you are TeX: The Program and METAFONT: The Program, because these are simply the best-written, best- documented, best-debugged programs of their size ever published. They reward careful study._

I've tried to read the source for _TeX: The Program_ (I actually have the boxed set he mentions), but was impeded by my lack of knowledge of TeX. I keep meaning to get back to it.

[1] Guy's list in archive.org: [http://web.archive.org/web/20080422183814/http://www.bookpoo...](http://web.archive.org/web/20080422183814/http://www.bookpool.com/ct/184)

</comment></comment></comment></comment></comment></comment><comment><USER4> Literate programming is a thing that's long piqued my interest, but it usually seems more suited to academic or personal use.

Having said that, a beautiful example of LP in the wild is geom[0], a Clojure/Clojurescript library written entirely in org-mode. Browsing through the source, I have to keep reminding myself that I'm looking at the code and not just the documentation.

[0] [https://github.com/thi-ng/geom](https://github.com/thi-ng/geom)

<comment><USER5> I see that this is a honorable goal, but in this particular project the source looks more like source than documentation. An extreme example is this part, where the code even contains function docstrings, rather than having the docstring as part of the surrounding document:

[https://github.com/thi-ng/geom/blob/master/geom- core/src/mat...](https://github.com/thi-ng/geom/blob/master/geom- core/src/matrix.org#view-matrix-generation)

This is an effect which I observed with my own literate programming attempts, too: They quickly end up with large documents that contain lots of code listings and not much explaination.

<comment><USER6> Author here: Agreed & most parts of this particular project aren't really the best example. With other (newer) projects I embraced the LP style much more, and in fact by now really often first write the prose parts to get my head clear about a certain aspect and only then start writing code, e.g.

[https://github.com/thi-ng/fabric/blob/master/fabric- facts/sr...](https://github.com/thi-ng/fabric/blob/master/fabric- facts/src/dsl.org) [https://github.com/thi- ng/geom/blob/develop/src/viz/core.org](https://github.com/thi- ng/geom/blob/develop/src/viz/core.org)

As for the docstrings included in the core, this is largely to address complains from other users, who are used to have docs available in the REPL and I often don't have the resources/time to provide both org-mode and docstrings...

</comment></comment></comment><comment><USER7> It would help if editors stopped treating comments as second-class content. Most atom themes, for example, render it as I would render unused code (if I were to commit such atrocities) – grey on (light|dark) grey.

I wish there were a functioning plugin to render markdown inline. I bet people would start caring about comments just because they looked better.

<comment><USER8> One thing I've been doing for a few years now is minimizing syntax highlighting for code, and using some of the colors I save to have different kinds of comments with different colors: [http://i.imgur.com/vU783Xo.png](http://i.imgur.com/vU783Xo.png)

Here's the initial idea that led to this: [http://akkartik.name/post/2012-11-24-18-10-36-soc](http://akkartik.name/post/2012-11-24-18-10-36-soc). As you can see, it was in turn spawned by.. a comment on HN :)

</comment></comment><comment><USER9> Language or "human order" is pretty cumbersome to express ideas. It is full of double meanings, assumption and expectations.

Any attempt to express complicated and precise ideas in natural language results in hard to understand gibberish. And you will need special training to decipher it anyway. Law is good example.

I think programming languages as we have them are good for instructing computers.

<comment><USER10> Programming languages were designed for people, compilers are designed to interpret that language into instructions for the computer.

Natural language is horrible for a programming language, but don't forget that the reason we write code in higher level languages is specifically to make it easier for humans, not for computers.

</comment></comment><comment><USER11> My latest attempt at this problem is a tool I call `cq` [1]. It's a way to query code with a selector, rather than line numbers. I use it for blog posts to pull code chunks into markdown.

It lets you write a (static) document that mixes prose and code in a way thats best for the reader. But 1. the code is runnable on disk and 2. you don't have to copy and paste.

Generally I find that literate programming solutions don't have good support for hiding portions of the code. This tends to limit the tool's applicability to trivial code examples.

I use `cq` to extract key code blocks from complete projects and then provide the whole project alongside the post.

[1]: [https://github.com/fullstackio/cq](https://github.com/fullstackio/cq)

</comment><comment><USER12> It seems to me that well-documented code should follow some sort of power law:

Each line should be documented (best if self-documented).

Each function (of around 10 lines) should be documented.

Each group of functions (of around 100 lines total) - approximately a class - should be documented.

Each module (of around 1000 lines) should be documented.

.. etc. up to the final documentation about the whole program.

Each level of documentation should summarize the purpose, inputs, outputs, assumptions and architecture of the thing being described. So a higher level should be around 10x smaller part of the total documentation (of course, some other factor could be used).

</comment><comment><USER3> There was a fantastic set of panel discussions at MIT on dynamic languages in 2001. In the Q&A period of the panel on runtime [1] Guy Steele asked the panel what they thought about literate programming [2], and some good discussion ensued. Some points made that I particularly liked were the point that people generally don't even make the effort to keep comments up-to-date, much less writing them well in the first place, never mind thinking about a good order for the human to read them in.

[1] [https://www.youtube.com/watch?v=4LG- RtcSYUQ](https://www.youtube.com/watch?v=4LG-RtcSYUQ)

[2] [https://www.youtube.com/watch?v=4LG- RtcSYUQ#t=1h21m43s](https://www.youtube.com/watch?v=4LG-RtcSYUQ#t=1h21m43s) (discussion lasts about five minutes, participants include David Moon, Scott McKay, and Guy Steele)

</comment><comment><USER13> Org mode is very good, if not the best, way to do literate programming. My blog post about it: [https://kozikow.com/2016/05/21/very-powerful-data- analysis-e...](https://kozikow.com/2016/05/21/very-powerful-data-analysis- environment-org-mode-with-ob-ipython/). I use it at work for data analysis and "researchy" projects.

Many of my blog posts at kozikow.com are written in the literate programming style in org mode, and you can see the org files at [https://github.com/kozikow/kozikow-blog](https://github.com/kozikow/kozikow- blog).

People have written whole books in it: [https://github.com/jkitchin/pycse](https://github.com/jkitchin/pycse).

</comment><comment><USER14> The first comment, written by none other than Peter Norvig, is also worth reading.

EDIT: link - [http://www.johndcook.com/blog/2016/07/06/literate- programmin...](http://www.johndcook.com/blog/2016/07/06/literate-programming- presenting-code-in-human-order/#comment-871292)

<comment><USER15> His comment sums up exactly my thoughts wrt literate programming. It sounds like a nice idea, but in practice it falls far short.

The worst program I've ever had to maintain was written in funnelweb. It was a large, complicated program, so the funnelweb-generated documentation was tens of thousands of pages long. Nobody was ever going to read that. Trying to find out what you needed to modify to fix a bug was impossible from that document. Most developers I know looked at the woven C code (after all, that's where the line numbers in the stack trace pointed to), and worked from there.

</comment></comment><comment><USER16> We have tools that let you examine code from various angles. There is no need to encode some "human order" in the code itself. Code should be organized in the way that harmonizes with the module structure and promotes maintainability, without regard for some "human order" nonsense.

Who decides what is "human order"? Humans want things in different order for different purposes. For example, business software generates all sorts of reports of different kinds from the same data.

This is wrong:

> _Traditional source code, no matter how heavily commented, is presented in > the order dictated by the compiler._

This is only true of one-pass, strict definition-before-use, single-module- only programming languages, like toy versions of Pascal.

In any decent language, we can take exactly the same program, and permute the order of its elements with a great deal of liberty, and present them in that order to the compiler. We can decide which functions go into which modules, and we can have those functions in different orders regardless of what calls what.

Ah, but some of the more crazy proponents of literate programming are not satisfied with that granularity. It bothers them that the individual statements of a program that are to be executed in sequence have to be presented to the compiler in that sequence: S1 ; S2.

Knuth's outlandish version, in particular, stretches the meaning of "literate" by turning code into a dog's breakfast in which functions are chopped into blocks. For compilation, these blocks are re-assembled by the "literate" processor into functions.

The result is difficult to understand. Yes, the nice explanations and presentation order may present something which makes sense. But here is the rub: _I don 't just want to follow the presentation of a program, I want to understand it for myself and convince myself that it is correct._ For that, I need to ignore all the text, which, for all I know, only expresses the author's wishful belief about the code.

</comment><comment><USER17> I understood the concept of literate programming of a way to organize _source code_ in such a way that it 'flows' better for a human, i.e. it starts with the methods/functions/modules/blocks where you naturally would start if you were to explain your code and then on to the next method/function/module/block that you would explain. Perhaps some comments here and there to explain where to start and what are special points of interest. I should have read the wikipedia article I suppose where it seems to be actual prose... :) Now I am not sure I like the idea - always found well-written source code to be easier maintainable and understandable than prose...

<comment><USER18> Look at Knuth's Adventure example: [http://www.literateprogramming.com/adventure.pdf](http://www.literateprogramming.com/adventure.pdf)

Plenty of code with your prose there.

<comment><USER15> I hero-worship Knuth as much as anyone, but that document is frankly terrible.

Take a look at section 6. There's a flowery sentence that says no more than "Add word to vocabulary" (completely pointless if this were a method called "add_word" on a class named "Vocabulary") and then a dense chunk of completely unexplained code.

<comment><USER19> I think the issue is treating Knuth's literate programming examples as received wisdom, or the pinnacle of the form, rather than as a pioneering effort by someone very talented, but done without the benefit of a developed culture around the practice. He makes mistakes we have memes now for (e.g. "explain why not how", useless comments for imports). I think if literate programming takes off, we'll see the form surpassing Knuth quickly

</comment></comment></comment></comment><comment><USER20> The problem with most programming languages is that programmers write programs in it by incrementally adding to the code in random places.

I think we need a programming language that allows programmers to build programs by merely adding things to the bottom of the source file.

<comment><USER21> That's a REPL which can save its state to a file :)

</comment></comment><comment><USER22> The best way to document a program is to prove its correctness. Short of that, it is usually no fun to deal with other peoples (or your own old ones) programs anyway.

As for presenting things in the right order: This order would largely be imposed by a correctness proof. As there could be different proofs, there could be different orders.

Obviously, not all programs can be proven correct (but I think a very large part of all programs could be). Also, finding the right order is not as difficult as finding the right level of abstraction. Once you have the right level of abstraction for presenting something, everything else flows from that.

</comment><comment><USER23> I wrote this before, a previous time the subject came up. people seemed to find it useful then, so maybe they will now as well:

A previous employer (a subdivision of a global top ten defence company) used literate programming.

The project I worked on was a decade-long piece for a consortium of defence departments from various countries. We wrote in objective-C, targeting Windows and Linux. All code was written in a noweb-style markup, such that a top level of a code section would look something like this:

        <<Initialise hardware>>
        <<Establish networking>>

and so on, and each of those variously break out into smaller chunks

        <<Fetch next data packet>>
        <<Decode data packet>>
        <<Store information from data packet>>
        <<Create new message based on new information>>

The layout of the chunks often ended up matching functions in the source code and other such code constructs, but that wasn't by design; the intention of the chunks was to tell a sensible story of design for the human to understand. Some groups of chunks would get commentary, discussing at a high level the design that they were meeting.

Ultimately, the actual code of a bottom-level chunk would be written with accompanying text commentary. Commentary, though, not like the kind of comments you put inside the code. These were sections of proper prose going above each chunk (at the bottom level, chunks were pretty small and modular). They would be more a discussion of the purpose of this section of the code, with some design (and sometimes diagrams) bundled with it. When the text was munged, a beautiful pdf document containing all the code and all the commentary laid out in a sensible order was created for humans to read, and the source code was also created for the compiler to eat. The only time anyone looked directly at the source code was to check that the munging was working properly, and when debugging; there was no point working directly on a source code file, of course, because the next time you munged the literate text the source code would be newly written from that.

It worked. It worked well. But it demanded discipline. Code reviews were essential (and mandatory), but every code review was thus as much a design review as a code review, and the text and diagrams were being reviewed as much as the design; it wasn't enough to just write good code - the text had to make it easy for someone fresh to it to understand the design and layout of the code.

The chunks helped a lot. If you had a chunk you'd called <<Initialise hardware>>, that's all you'd put in it. There was no sneaking not-quite- relevant code in. The top-level design was easy to see in how the chunks were laid out. If you found that you couldn't quite fit what was needed into something, the design needed revisiting.

It forced us to keep things clean, modular and simple. It meant doing everything took longer the first time, but at the point of actually writing the code, the coder had a really good picture of exactly what it had to do and exactly where it fitted in to the grander scheme. There was little revisiting or rewriting, and usually the first version written was the last version written. It also made debugging a lot easier.

Over the four years I was working there, we made a number of deliveries to the customers for testing and integration, and as I recall they never found a single bug (which is not to say it was bug free, but they never did anything with it that we hadn't planned for and tested). The testing was likewise very solid and very thorough (tests were rightly based on the requirements and the interfaces as designed), but I like to think that the literate programming style enforced a high quality of code (and it certainly meant that the code did meet the design, which did meet the requirements).

Of course, we did have the massive advantage that the requirements were set clearly, in advance, and if they changed it was slowly and with plenty of warning. If you've not worked with requirements like that, you might be surprised just how solid you can make the code when you know before touching the keyboard for the first time exactly what the finished product is meant to do.

Why don't I see it elsewhere? I suspect lots of people have simply never considered coding in a literate style - never knew it existed.

If forces a change to how a lot of people code. Big design, up front. Many projects, especially small projects (by which I mean less than a year from initial ideas to having something in the hands of customers) in which the final product simply isn't known in advance (and thus any design is expected to change, a lot, quickly) are probably not suited - the extra drag literate programming would put on it would lengthen the time of iterative periods.

It required a lot of discipline, at lots of levels. It goes against the still popular narrative of some genius coder banging out something as fast as he can think it. Every change beyond the trivial has to be reviewed, and reviewed properly. All our reviews were done on the printed PDFs, marked up with pen. Front sheets stapled to them, listing code comments which the coder either dealt with or, in discussion, they agreed with the reviewer that the comment would be withdrawn. A really good days' work might be a half-dozen code reviews for some other coders, and touching your own keyboard only to print out the PDFs. Programmers who gathered a reputation for doing really good thorough reviews with good comments and the ability to critique people's code without offending anyone's precious sensibilities (we've all met them; people who seem to lose their sense of objectivity completely when it comes to their own code) were in demand, and it was a valued and recognised skill (being an ace at code reviews should be something we all want to put on our CVs, but I suspect a lot of employers basically never see it there) - I have definitely worked in some places in which, if a coder isn't typing, they're seen as not working, so management would have to be properly on board. I don't think literate programming is incompatible with the original agile manifesto, but I think it wouldn't survive in what that seems to have turned into.

<comment><USER24> This seems a lot like cucumber, which is basically a regex expander until it gets down to real code eventually.

I have found this style very frustrating when doing anything complex that's also reused a lot. Particularly because the flow of information (expressed in normal code as variables and arguments) can become very subtle and tightly coupled when it's buried at the very bottom of an expanded expression. Maybe this is a solved problem in the system you're taking about, but I have a really hard time seeing how.

<comment><USER23> "This seems a lot like cucumber, which is basically a regex expander until it gets down to real code eventually."

It's not at all like that. I must have explained it badly. Cucumber is written for a machine. This was written for humans. Not shown; design discussion, diagrams, links to requirements, pieces of history, and everything else that was helpful for humans to understand the software from requirements to design to implementation.

<comment><USER24> Ah, re-reading I think I see where I went wrong. So code is written separately, but cross linked with these document identifiers?

<comment><USER23> Broadly speaking, yes. The programmer might have written something like this:

        The principal components (message queue, network connector, message handler) are all necessary. They are initialised together, and if any one fails, the program should be aborted.

        <<Initialise message queue>>
        <<Initialise network connector>>
        <<Initialise message handler>>

        Each initialisation signals success or failure independently, but a global "Error state" object exists; any catastrophic error found will trigger an abort of program with logging.

        <<Check catastrophic error state>>

        The message queue feeds itself directly from the network. It needs only be made aware of the connector. This was not done during initialisation for reasons x, y, z.

        << etc etc >>

Somewhere else might be a piece that looks like this:

        The message queue initialisation is very simple; it's using a library standard queue. See meeting minutes 3452/r for further detail.

        <<Initialise message queue>>=
        // ACTUAL CODE

The document contains various markup explaining the order of the code, and the order of the human readable sections; upon munging, the human gets a beautiful PDF that intersperses code with design discussion in a good order for the human to read and understand (and consequently review and test, so we've got ourselves a virtuous cycle here), and the machine gets just the code. For the machine, each << XXX >> pieces gets replaced with other << YYY >>, recursively, until it's just code.

Because it's munged, there can be a chapter discussing everything there is to know about a single class, for example, and a chapter discussing System Initialisation, or whatever else fits to the needs at hand. If someone wanted to know about initialising the system, they PDF had the broad top-level discussion, and a break down of smaller sections. The reader could then dig into each as deep as they liked, at each stage seeing the design discussion/diagram, and as much of the code detail as they liked.

It made working on code I'd never seen before an absolute dream. By the time I reached the actual code, I already knew what it was meant to do and how it worked.

On the one hand, a lot of extra work, and it does constrain the coding style you can use; it only makes sense with code that _can_ actually be broken into smaller, meaningful pieces like that. On the other hand, zero bugs found by our customer, the prime contractor. QA and testing and everything else was a massive part, but it all helped. I know the prime contractor was definitely doing some serious testing, because we watched them sue one of the other contractors for general incompetence.

</comment></comment></comment></comment></comment><comment><USER25> Regarding the tangle barrier issue, there is a tool that helps: [https://github.com/aryx/syncweb](https://github.com/aryx/syncweb) It allows to modify both the original WEB document and code and keep them in sync.

</comment><comment><USER26> I am a fan of the literate programming style for personal projects.

For a very well executed and interactive example check out

[http://dave.kinkead.com.au/modelling-the-boundary- problem/](http://dave.kinkead.com.au/modelling-the-boundary-problem/)

</comment><comment><USER27> My main problem with literate programming is that it is difficult enough to keep short comments up to date vis-a-vis the code they describe. Longer comments would be even worse.

I also suppose the modern equivalent of this, in many use cases, is a Jupyter notebook.

<comment><USER28> _My main problem with literate programming is that it is difficult enough to keep short comments up to date vis-a-vis the code they describe. Longer comments would be even worse._

Perhaps counter-intuitively, I have found the opposite to be the case so far. It's all too easy to overlook a couple of small comments out of 20 when you update a screenful of code. You can't really miss a whole paragraph of text that separates a few lines of code you're working on from everything else.

I've also found that with literate documentation the emphasis is naturally on explaining the big picture and why things are being done, and that kind of information tends to remain relevant through minor code changes anyway.

You can still add short comments about particular points in the code as well, and maintaining those is much the same whether you're using literate programming or not.

</comment></comment><comment><USER29> The F# Formatting library lets you do things like re-order code and hide less important code for documentation purposes. You can create clean documents presenting code as a narrative. [http://tpetricek.github.io/FSharp.Formatting/literate.html](http://tpetricek.github.io/FSharp.Formatting/literate.html)

</comment><comment><USER28> I've been using Literate Haskell for a project recently. It's a heavily mathematical data-crunching algorithm, in the region of a few thousand lines of executable code. This is the first time I've tried writing literate code in a major professional project, and it's been interesting to see how the reality matched up with my initial expectations.

To me, the biggest practical difference is whether your documentation is primarily written as a tutorial or for reference on demand. Presenting ideas in a natural order for tutorial purposes is useful to someone coming to the code for the first time, or if you're coming back to look at a module a while after you first wrote it when all those little details are no longer so familiar.

In my case, the documentation is generated using LaTeX and so can also include maths, diagrams, tables and other illustrative material right there next to the associated code, as well as providing a natural place to put module- or program-wide summary information to give an overview of how everything fits together. Like a mathematical paper, it takes a little effort to present all this extra documentation well. However, it's hard to overstate how much better it is if you're trying to understand some intricate mathematical code that you wrote three months ago and the actual maths is right there and is then directly reflected in the shape of the code.

Others have mentioned that literate code might be harder to maintain in the long run. I'm not sure how realistic that really is, based on my experience so far. If you're making code changes significant enough that you'd want to reorder the whole presentation, you're probably rewriting significant chunks of that documentation anyway, and it's not as if our editing tools can't cope with moving code and/or text around.

What does suffer, significantly in my experience, is the _scannability_ of the code. Those few thousand lines of Haskell I mentioned produce well over 100 pages of typeset documentation at this point. That's partly because of the extensive textual notes and mathematics and diagrams and so on. It's also partly because typeset documentation is naturally more spaced out because of things like headings and blank lines. But the fact remains, if I looked at just the source code in my usual editor, I'd probably have 50–100 lines visible in a single window, and I can open several of those windows at once on a big screen. If I'm looking through the literate documentation (or the source file from which it is generated) then I am probably only seeing one third to one half of that at most, and crucially, that code only appears a few related lines at a time, often a single function or a small family of related type definitions. Since Haskell itself is rather uniform in appearance and tends to be written by composing very short elements anyway, this makes finding and understanding individual fragments of code noticeably harder than regular coding when you want to refer back to something in isolation.

So far, I'm finding that a price worth paying, at least for this kind of heavily mathematical work with me as the sole developer. In practice, I don't actually want to refer to a small code fragment on its own very often. I'm more likely to come back to a whole module, skim the entire literate documentation for it (probably just a few pages) to remind myself of how it all fits together, and then not need to jump around understanding small individual elements in isolation. Still, there is definitely a cost here, and it definitely affects how I read and understand the code as I'm working with it later. I suspect some of that cost would be incurred anyway by using Haskell, or any other language and programming style that emphasize composing many small elements, but using literate programming does exaggerate the effect, and so far I've found that to be its biggest drawback over more conventional styles.

<comment><USER18> That's very interesting.

I wonder whether a `show me the code only' view would be useful?

I have written some short literate Haskell pieces, but nothing more than executable blog posts.

<comment><USER28> _I wonder whether a `show me the code only ' view would be useful?_

What I personally miss most is the ability to look at code from different perspectives and navigate it in different ways.

I find writing in a literate style is much more like preparing an academic paper or formal presentation than like programming as I usually would. There's a clear order of doing things, but there's only _one_ order, a very static form of presentation and reading. As I mentioned before, I find this can work quite well when the work actually is heavily mathematical and relies on careful and systematic construction of the final result, but like working with math papers, it's definitely an "acquired taste" and takes some getting used to.

In contrast, when I'm programming in most other languages, I rapidly navigate all over the code to follow relationships and definitions and so on. We have lots of tools to help do that quickly and easily in any modern programmer's editor or IDE. We also have lots of ways to display different parts of the code and visualisations of the relationships between them simultaneously. I really miss that sort of dynamic, flexible working environment with the Literate Haskell. Sadly, I've yet to discover any programming environment that supports both the documentation side (essentially a good editor for working with LaTeX and the related tools) and the programming side (more like an interactive IDE).

To be fair, this feeling is probably due in part to my own relative inexperience with Haskell projects on this scale. Although I've long been interested in functional programming and used it for various bits and pieces over the years, my large-scale, professional projects have generally used more mainstream languages like C++, Python and JavaScript, and the tools and environments that go with them. Functional programming has a rather different feel anyway, and perhaps I just haven't learned to combine that more mathematical/functional mindset, literate programming style, and the available tools as well as I could yet.

In any case, I definitely believe there's a lot of potential for new tools in this area, combining the kind of documentation and structured presentation I'm seeing with the literate code with the kind of dynamic, on-demand exploration of code that modern IDEs for many other languages offer.

<comment><USER18> I've been using Haskell a lot (even professionally for 5 years). None of my commercial Haskell coding was literate, though. That has been restricted to smaller explanatory pieces.

We do jump around in the programming editor when doing Haskell. Eg jump to definition is just as useful as for other languages.

<comment><USER28> May I ask what you use for editing your Haskell code?

For the literate project I'm using my usual programmer's editor. It handles switching between the LaTeX and Haskell reasonably well in terms of syntax highlighting, but it does lack most IDE-like features, even with any of the extra packages I've tried installing so far.

A tool that provided reasonably reliable go-to-definition functionality would certainly be a helpful addition, and the kinds of pop-up help you get in IDEs to keep track of function parameters and their types seem particularly relevant to a language like Haskell, but I've yet to find an environment that both offers those features and handles the documentation aspects well.

<comment><USER18> I've never tried the LaTeX literate Haskell in earnest, only the > kind.

I've been using Emacs, Vim to edit Haskell, and at Standard Chartered Visual Studio to edit their Haskell dialect.

Go-to-definition and display-type-of-expression-at-cursor can be done in Vim and Emacs already.

</comment></comment></comment></comment></comment></comment><comment><USER30> Is the Knuth book on literate programming any good?

Anyway I thought this article would have been better with a few examples. I'm still not any closer to understanding how the tangling process works.

<comment><USER31> I've read Knuth's article on this and here's my thoughts. It's meant to be used with a single language (Pascal), which is sometimes good (because the tool really understands Pascal and can parse these code snippets to produce a cross-reference), but it's also a curse, because many of the tool's constructs are actually workarounds for Pascal shortcomings. Also, it only generates a single file, but today's projects are both multi-file and multi-language. So it's a bit dated.

I think the idea itself is so simple it doesn't really need any extensive book. Basically you take any text preparation system and add three elements: a code fragment, a reference to a code fragment, and a file, which is a fragment that will be written to disk.

(I myself use such a system based on reStructured Text. I want to post it on Github when it's ready, but it's not there yet, so I cannot show exactly how it works. But I use it to write a moderately complex personal project with C and Python mostly, and all the tooling, e.g. Makefiles. I found it very helpful; it does make the code much cleaner, that is it strongly urges you to. And it's invaluable when you want to remember why you did things that way.)

<comment><USER32> Isn't Knuth's CWEB used for C?

<comment><USER31> CWEB is for C and the original WEB was for Pascal. (C is a good fit, by the way, because you can use #line directive to make the compiler to report the line numbers in your original literate files instead of the irrelevant line numbers in generated files.) But as far as I remember it still produces a single C file and a single TeX file.

<comment><USER33> When experimenting with NOWEB and Java (1.3 I believe) I discovered that one of the things that those LP systems did was encourage something like macro based code re-use, somewhat "lifting" the rather basic language up towards something a little more high level. This was good and bad; bad like unhygienic macros can be bad.

As far as I could figure out it was a poor match for OO/"inheritance oriented" programming. It was a better match for procedural style programming - "writing C in java" \- then the LP "macros" didn't confuse things. But when mixing OO- style java, I found things seemed to become uncomfortably verbose.

NOWEB might in some ways be the worst of both worlds - it knows (and cares) nothing about the programming language - but that also means blocks can't be parameterized. This is annoying if you're using variables to hold iterators and state (traversing a graph stored in arrays as edge/node lists etc). You end up with dangerous variable name re-use or code duplication (and too big code blocks).

</comment></comment></comment></comment></comment><comment><USER34> Literate programming - the original IPython notebook

</comment><comment> obj-g "I think I understand better now why literate programming hasn't gained much of an audience. I used to think that it was because developers hate writing prose. That's part of it."

Right, and that's why it's _so_ difficult to find developer-written blogs and articles and tutorials online....

<comment><USER35> Paraphrasing Knuth, the intersection of good writers and good programmers is small. That doesn't stop people like me from making attempts at writing blogs and articles, but it doesn't make them good. It also doesn't mean that people won't write one-off articles and blogs, but may not be interested in doing that essentially daily (what the literate style kind of requires).

<comment> obj-g Your point is taken, I just take issue with the article perpetuating such a stereotype. I'm a developer, I have a degree in literature and write a ton. And the article says nothing about developers not writing _good_ prose, just not liking to write prose period. The intersection between _anything_ and _good_ writers is pretty slim, to be honest. The author just supposes that developers don't like writing prose. Which is silly. At least in my opinion.</comment></comment></comment>


As usual, we are the product being sold - <AUTHOR> http://www.marco.org/2011/09/09/twitter-doesn-t-give-a-damn-who-you-are <comment><USER2> for someone that is complaining about twitter, he uses it quite frequently.

For every time I hear someone complaining about "being the product", its simple just don't use it.</comment>


Ask HN: How are 3D printing related startups doing lately? - <AUTHOR> Just curious about how 3D printing startups have been doing in the recent year - both software and hardware. 3D printing got pretty huge a year or two ago and now I don't seem to hear much about them in the media. Not sure if the industry is still growing or have VCs stopped funding them. <comment><USER2> I think its moving towards B2B after the consumer novelty wore off: [http://www.builtinboston.com/2017/07/31/why-google-nasa- and-...](http://www.builtinboston.com/2017/07/31/why-google-nasa-and-us-air- force-flocking-3d-printing-startup-markforged-0)</comment>


California Warns About Cell Phone Exposure and Health Risks - <AUTHOR> https://www.forbes.com/sites/alicegwalton/2017/12/16/california-warns-about-cell-phone-exposure-and-health-risks <comment><USER2> From abstract of a paper that is being referred to :

[http://www.sciencedirect.com/science/article/pii/S1877782110...](http://www.sciencedirect.com/science/article/pii/S1877782110001517)

> Background: There is continuing public and scientific interest in the > possibility that exposure to radiofrequency (RF) electromagnetic fields > (EMF) from mobile telephones or other wireless devices and applications > might increase the risk of certain cancers or other diseases. The interest > is amplified by the rapid world-wide penetration of such technologies. The > evidence from epidemiological studies published to date have not been > consistent and, in particular, further studies are required to identify > whether longer term (well beyond 10 years) RF exposure might pose some > health risk...

> Conclusions: A prospective cohort study conducted with appropriate diligence > and a sufficient sample size, overcomes many of the shortcomings of previous > studies. Its major advantages are exposure assessment prior to the diagnosis > of disease, the prospective collection of objective exposure information, > long-term follow-up of multiple health outcomes, and the flexibility to > investigate future changes in technologies or new research questions.

So basically people are worried, but there isn't any evidence found that supports the theory that there is an issue.

And the study?

[https://academic.oup.com/ije/article/46/3/775/3038111](https://academic.oup.com/ije/article/46/3/775/3038111)

A total non-conclusion that talks about how to conduct a study. Oh, and people who use phones a lot might get fat. Implementing regulations or guidelines with a complete lack of supporting evidence looks to me like a complete waste of money.</comment>


Can Science Rule Out God? - <AUTHOR> https://blogs.scientificamerican.com/observations/can-science-rule-out-god/ <comment><USER2> Science may rule out god, but not religion, for each religion is management and psychology science to avoid disorder and chaos.</comment>


Finland plans to give every citizen a basic income of 800 euros a month - <AUTHOR> http://www.msn.com/en-us/news/world/finland-plans-to-give-every-citizen-a-basic-income-of-800-euros-a-month/ar-AAg3Bn1?ocid=ansmsnnews11 <comment><USER2> Not for minors though. Hope this fact doesn't make an example not to follow for other countries.</comment>


Startup Ketamines - <AUTHOR> http://www.tomscott.com/startupketamines/

<comment><USER2> For those who like demotivational posters, see also [http://www.despair.com/demotivators.html](http://www.despair.com/demotivators.html).

Here's one that could relate to startups:

[http://www.despair.com/acquisition.html](http://www.despair.com/acquisition.html)</comment>


Ten years ago they beat MIT. Today, it's complicated (2014) - <AUTHOR> http://www.azcentral.com/story/life/az-narratives/2014/07/17/phoenix-high-school-win-mit-resonates-decade-later/12777467/ <comment><USER2> As a poor Mexican from Arizona who went to MIT, this story hits close to home. But after much reflection, I believe the sad reality has a enduring positive legacy which has only begun.

While perhaps not following the paradigm of success we on HN often consider, the team's victory in the competition and subsequent publicity became a widely distributed step-function for an entire generation of down trodden Latinos. Although anecdotal, I've witnessed a large swath of family and friends become engineers, go to med school or start their own business. This viable reality was made possible by the previous generation taking chances and working incredibly hard.

I admit that I've been envious in the past of my immigrant friends with parents who are from India, China and Korea, where studiousness and achievement are default conditions for upbringing. But I'm excited to see an inflection point in the Mexican culture and it starts with stories like these!

<comment><USER3> It's harder for unskilled labor to emigrate across the Pacific. I knew plenty of underachievers in Beijing.

Most of the hispanic people I met through school or work were recent immigrants from upperclass families. However, one of my Columbian classmates at MIT grad school was the son of a janitor. He founded a startup after graduation. If we calculated a ratio for achievement vs our parents' occupations then he has one of the highest scores.

Here is the link to his company. [http://www.skulpt.me](http://www.skulpt.me)

</comment></comment><comment><USER4> This demonstrates a tragedy that happens all too often. How many talented people out there have their talents wasted because of barriers like this. How many people can't fulfil their potential because they're born into a poor family or on the wrong side of an arbitrary border?

<comment><USER5> Sometimes a border is not a border, it is scar. An ethnic group was already living in that area and one day they find themselves at one side of the fence.

<comment><USER6> You are very right, especially places like colonial Africa. However in the context of California, Arizona, etc much of the immigration is from Guatemala, Central America, etc, not the true native tribes like the Chumash, Luiseño, et al who are still here.

Just pointing this out because "division" gets bandied about a lot inaccurately.

<comment><USER5> I am thinking about "El Norte".

[http://www.tufts.edu/alumni/magazine/fall2013/features/up- in...](http://www.tufts.edu/alumni/magazine/fall2013/features/up-in-arms.html)

</comment></comment></comment></comment><comment><USER7> I was on a First Robotics Competition team in high school and interacted with Falcon Robotics, (Team 842), a few times. They're well regarded as one of the best and most gracious teams in the competition.

</comment><comment><USER8> I don't know the specifics of the current reasoning or history that Arizona has with immigration but at a base level I'm pretty infuriated that these kids actually have the desire to do hard things that society needs and got thwarted. I know there are rules but how many potential new engineers (is there still a big shortage?) are we letting slip through the cracks?

<comment><USER9> Does "illegal" in this (immigration) context have a more subtle meaning in the USA?

When the article says he lost his place when voters pulled scholarship money from "people in the country illegally", I read that and think, well I'm not surprised - surely if the university is aware that somebody is in the country _illegally_ then they have a duty to report it to the authorities, and certainly not offer them studentship - nevermind a scholarship?!

<comment><USER10> The question is whether children should be blamed for what their parents did. Many people would say no.

<comment><USER9> It's not really about blame though, surely, it's just about upholding the law.

The child of an illegal immigrant is there illegally, they're not to blame, but they're illegal residency surely shouldn't be supported.

An analogy might be distributing inheritance evenly, because "children shouldn't be blamed for what their parents did [and how much they made doing it]".

Some people might argue we should do that... but even they'd surely agree it's pretty extreme.

Just seems like a rather ambivalent relationship with immigration law to me. But hey, that's just my outsider's point of view!

<comment><USER11> >but they're illegal residency surely shouldn't be supported.

Then provide 0 medical services, CPS services, police services, or legal system services. If you have someone here illegally, especially a child, being targeted by a predator, it sucks. Really bad. But to offer them any services paid for by the American people is supporting their illegal residency.

I find that most people who push for the view of not supporting legal residency in cases such as school care or even medical care are still willing to do so when you talk about the illegal resident being the target of a predator. This makes me think that either they don't fully accept their own logic or that there is something else at play that they didn't expand upon.

</comment></comment></comment></comment></comment><comment><USER12> I watched the documentary around a year ago and was really inspired by the team. It's sad to hear what happened to them to be honest. Such brilliant minds put to waste.

<comment><USER13> Possibly they were all better off though, after their win, than they would otherwise be. It's both heartbreaking and inspiring what became of them. Heartbreaking: that not even one became an engineer or had greater (Hollywood ending style) success. Inspiring: that they struggle hard and have some success against formidable odds. Also sad that the Phoenix school to this day has to scrounge for equipment and funds. Lots of players dropped the ball here, the Arizona state, companies, enterprises, MIT. MIT could have gotten immense goodwill by partnering up somehow with the Phoenix school. An off-site campus or something, anything really.

<comment><USER14> One graduated from ASU with an engineering degree and works as a supervisor.

</comment></comment></comment><comment><USER15> Often stories of this sort are used to advocate a more permissive immigration policy, particularly toward those from Mexico and South America who have entered the US illegally seeking economic opportunity.

Rational arguments seldom make their way into this discussion, if it can be called that.

On the one side we have the empathetic liberals, who in many cases ultimately wish to see the complete abolition of national borders and global inequality. Joining them are corporations, which want abundant labor in order to reduce the costs of employment.

On the other, we have low-skilled citizens, who don't wish to see their quality of life reduced by admitting large numbers of people willing to work for very little. Along with them are those concerned about the political and cultural consequences of admitting a massive, homogeneous, and very different group of people into their homeland. There are probably some racists among the group, though probably far fewer than the other side often claim.

Whichever side you find yourself on, I think the following must be admitted:

1) The ordinary citizen currently in the United States will likely experience a decline in quality of life as a result of a permissive immigration policy.

2) Massive economic migration to rich countries from poor ones is not a solution to the problem of global economic inequality or poverty.

3) Historical instances of immigration, colonialism, and invasion do not justify or necessitate permissive immigration policies in the present day.

<comment><USER16> >1) The ordinary citizen currently in the United States will likely experience a decline in quality of life as a result of a permissive immigration policy.

On what basis must this be "admitted"? You provide no rationale for it in the preceding paragraphs and then dump this line as if it should be obvious.

<comment><USER15> Ordinary people in the US benefit economically because of their citizenship. Many of these people possess few skills and would live in abject poverty doing the same work in other countries. Admitting large numbers of low-skilled workers increases the supply of laborers, with the result that competition for employment increases, and wages decline. Even with a minimum wage, the number of employment opportunities is reduced. Thus, ordinary citizens stand to experience a decline in their quality of life.

<comment><USER17> That's very simplistic analysis. The impact of immigration on the wages of native-born workers, even low-skilled ones, is definitely not a settled question [1].

[1] [http://blogs.wsj.com/economics/2015/06/01/does- immigration-s...](http://blogs.wsj.com/economics/2015/06/01/does-immigration- suppress-wages-its-not-so-simple/)

<comment><USER15> It's simplistic because of the format. Its intention is to explain the general line of reasoning to the person who asked for it, not provide an exhaustive analysis.

The article you've cited addresses immigration in general, not low-skill immigration by itself. This could support argument in favor of a selective immigration policy, not massive immigration of low-skill workers from developing countries.

</comment></comment></comment></comment></comment><comment><USER18> This is from 2014, maybe it should be marked as such. Incredibly touching story nonetheless.

</comment><comment><USER19> I cannot recommend more Spare Parts by Joshua Davis (the book the movie is based on). It does a great job explaining the situation these kids live in. (How can a kid go to college when their parents are sick and working 4 jobs to make ends meet?)

The real heroes here are not just the kids, but the teachers that with a non existent budget created a safe space for these kids to thinker and to use their natural talents

</comment><comment><USER20> Just a heads-up - this page auto-plays a video.

</comment><comment><USER21> > since his legal status prevented him from being an employee, but allowed him > to create his own company.

Come again?

<comment><USER22> The key here is that he is _hiring himself_ , so as _he is the employer (of himself)_ , and the liability for hiring an undocumented worker falls on himself.

Anyone can create a Delaware C corporation, even people from other countries who have never been to the US. You do need to be a citizen however to create an LLC or an S corporation.

<comment><USER23> Sorry this is incorrect anyone can create an LLC and a S corporation no need to be a US Citizen, at least in most states, can you pin point a state that requires US citizenship?

<comment><USER22> You're probably right. I got this information from an NYSBDC advisor[1] that I met with while I was in college.

(I wanted to do a startup part-time, but that dream was shattered after I found out from my school's immigration advisor that working for myself was prohibited.)

[1] New York Small Business Development Center (NYSBDC): [http://www.nysbdc.org/](http://www.nysbdc.org/)

</comment></comment></comment></comment><comment><USER24> This is a terrible clickbait title (currently "Ten years ago they beat MIT. Today, it's complicated")

</comment><comment><USER22> The entirety of blame for all of this pain, loss, and suffering falls squarely on the Republicans who oppose immigration reform, and keep calling for the merciless deportation of everyone including children who overstayed their visas or came over the border.

<comment><USER25> I think there are two issues there. One, the immigration rules. Two, the enforcement of those rules.

On the second, I have little sympathy for the category of people who intentionally break a law and then cry foul when that is discovered and addressed.

<comment><USER11> >On the second, I have little sympathy for the category of people who intentionally break a law and then cry foul when that is discovered and addressed.

So homosexuals put in prison because homosexuality is illegal in places (including the US not even 20 years ago)... no sympathy for them? OR... do you think not all laws are equal and that there are bad laws?

<comment><USER25> There are absolutely bad laws. There are also unconstitutional laws. I have no support for the latter, of course.

For bad but constitutional laws, we have a process for challenging and changing them. While they're in effect, I believe that if you're going to break them publicly, you should not expect to escape consequences.

<comment><USER22> Regarding constitutionality, FYI:

Back when the U.S. constitution was written, visas did not exists, and getting permission to immigrate was uncommon. You could literally walk into most countries without any papers. As such, the enumerated powers of Congress actually only contains the power "To establish an uniform Rule of Naturalization" (Article I, Section 8, Clause 4). Nothing about restricting immigration.

The US did not regulate immigration at all until the passage of the Chinese Exclusion Act (1882). The Act was challenged in the courts, and the SCOTUS ruled that Congress' power to "To establish an uniform Rule of Naturalization" meant that it could also exclude people from entering the country – which is quite a stretch. For more, see: [http://openborders.info/blog/immigration-](http://openborders.info/blog/immigration-)

Popular opinion at the time was that Chinese and other Asian people were unfit to be part of American society, and the SCOTUS was willing to stretch the meaning of those words in the Constitution to grant Congress the new powers necessary to exclude them.

</comment></comment></comment></comment></comment><comment><USER26> Yet another tragedy of regulation. Yes, I know unions want to keep competition for their services low, in the theory that they can extract higher wages. But the reality is, the people who want to come to america to work for companies are almost always going to have something that the existing people in america don't- either a willingness to do jobs that american's don't like or think are beneath them or skills that americans don't have in enough quantity.

Limiting immigration is limiting economic growth. The time when the country grew the fastest and most dramatically was also a time when shiploads of people were just showing up.

Every time you see someone saying "we need regulation for capitalism to work" these are their victims. Democrats and Republicans both have a history of denying people human rights, and the right to employ whomever I want-- without regard to where they were born-- in my business is a right that they are denying. It also denies the employee the right to work for whomever would like to hire them.

Government doesn't know best. This is why socialism has never worked.

So, if you're lamenting the way these people have been treated, look to your own voting history.</comment>


New super-Earth detected, 'best candidate' for supporting life - <AUTHOR> http://www.engadget.com/2012/02/03/new-super-earth-detected-best-candidate-for-supporting-life/ <comment><USER2> I often wonder if I'm "wrong" to think we should be putting so much more into raw exploration and colonization. Or at least experimenting with engines and probes. Sigh.

<comment><USER3> Why do you think you might be wrong?

The only real reason it might be "wrong" is that it might be excessively expensive in the hear-and-now to do compared to how easy it will be in the next few generations. Although SpaceX and other companies are bringing down costs so quickly regardless that such a point might be moot.

Nevertheless, consider. Right now it costs on the order of a dollar per gram to put anything in orbit. And considerably more to maintain something like a space station in orbit, or to launch something to another planet. This is independent of the cost of the thing itself, which tends to be even more expensive. However, imagine what the fruits of improving technology could bring. Imagine if we could make 100% automated factories where bulk materials go in one end and fully constructed launch vehicles come out the other end (with robotics, 3D printing, and who knows what else in the middle). Imagine if we had computers and simulations so good that you could make a digital model of a launch vehicle and you could simulate launch and reentry with enormous accuracy, including exploring possible failure modes. Imagine if you then apply a genetic algorithm to existing proven launch vehicle designs with the goal of reducing launch costs and improving reusability as much as possible, and with the massive computing power of the future at hand you can pop out incredibly advanced and incredibly cost efficient designs for getting to orbit, and then build tons of them with your robot factories.

In short, in the not too distant future we could easily end up in a situation where building orbital spaceships is on the scale of building automobiles or airplanes, and it's as easy to get into space as it is to travel on airplanes today, or possible easier. That would make today's inefficient and expensive methods look like a waste of effort in comparison.

However, that's generally true for just about anything we do today anyway, so I think it's probably worth keeping at it despite the difficulty.

<comment><USER2> The cost was my thought. I genuinely do go back and forth between "it's too expensive" and "cheaper to do it now than later".</comment></comment></comment>


DejaLu – Fast and Simple Email Client for Mac - <AUTHOR> https://www.dejalu.me/ <comment><USER2> The creator of Sparrow? [https://twitter.com/mronge/status/702160883888185344](https://twitter.com/mronge/status/702160883888185344) Then who is working on Google inbox?

</comment><comment><USER3> I've been using DejaLu for my Gmail the past couple weeks and it's FAST!

Going back to Mail.app is now painful. The sync speed and search are far superior in DejaLu.

I'm really excited to see where this app goes.

<comment><USER4> How do you get access to it?

</comment></comment><comment><USER5> When is this going to be available to buy/download?</comment>


Apple Is Working on a Dedicated Chip to Power AI on Devices - <AUTHOR> https://www.bloomberg.com/news/articles/2017-05-26/apple-said-to-plan-dedicated-chip-to-power-ai-on-devices <comment><USER2> This is probably going to be a hyper parallel fixed point / integer engine like TPU gen1. Doing fast matrix multiply over really small fields is very subpar on CPUs and GPUs. That was the initial reasoning behind TPU gen1 - improving runtime performance.

One question is if it will architecturally be closer to a GPU or an FPGA. The field moves so fast that it might make sense to "future-proof" a bit with a live-reconfigurable FPGA.

<comment><USER3> I'd bet on this being an ASIC, doing this on an FPGA with any serious size matrix would require a very expensive FPGA, whereas an ASIC would allow more gates in a smaller volume and would consume less power to boot.

From the manufacturers point of view phones not being future proof is a feature, not a bug, that way you'll upgrade to that new shiny item which will keep the profits rolling in.

<comment><USER4> > From the manufacturers point of view phones not being future proof is a > feature, not a bug, that way you'll upgrade to that new shiny item which > will keep the profits rolling in.

I don't think a better AI chip will be a convincing argument to change a phone one year later.

<comment><USER5> Not if you put it that way. Apple can simply make new AI features exclusive to newer phones with updated versions of the chips. If they open the chip up to developers, this effect can spill out to the app store. That would then provide the impetus to push consumers to upgrade.

<comment><USER6> You nailed the Apple plan, they did exact same thing staring from Introduction of Siri (4S?), ... then Force Touch etc.

With each iteration of phone, they add a shiny new feature that is ONLY available on the newer model.

<comment><USER7> i don't see how force touch can be added to older hardwares...

<comment><USER8> It can't be. Night Shift, on the other hand...

</comment></comment></comment></comment></comment></comment></comment><comment><USER9> Could this mean on-device ANI? My deal breaker with Amazon, Google, Microsoft and even Siri is their role in normalising the hoovering up of sensitive data.

<comment><USER10> More work needs to be done on training models with less data, differential privacy, and unsupervised learning, but so long as supervised learning continues to be the main path forward for the current set of "AI" centralizing the data into ginormous data sets will continue to be the norm.

<comment><USER11> I don't see how unsupervised learning makes this any better? That data you're training on in an unsupervised manner is still collected somewhere, and could contain as much private information as a labeled dataset.

<comment><USER12> Yep, whether it's supervised or not has no bearing on privacy. What counts is where the data is processed and who has it.

<comment><USER10> Labels for supervised training tend to come from humans in the loop. I think many would consider another human looking at their photos, searches, etc. To be a loss of privacy albeit with a small surface area.

</comment></comment></comment></comment></comment><comment><USER13> Why is Bloomberg not mentioning that Google announced it was working on the same thing? They mentioned vaguely that Amazon and Google both were working on AI, but nothing about the seemingly similar TPU and how Google announced they were going to bring it to phones at I/O just a bit ago. Am I wrong to be thinking that's pretty relevant here?

<comment><USER14> Because Google's TPU is for servers and not for Mobile.

<comment><USER13> Pretty sure they announced during I/O that they were working on making a TPU for mobile.

<comment><USER15> Do you have a link? I don't remember this, and I didn't find anything through googling.

<comment><USER16> I'm definitely doubting myself now. I remember watching the keynote and thinking how they didn't make a bigger deal out of the on device chip.

The only thing similar I can find is at about 1:22:00 in the keynote here [https://youtu.be/Y2VF8tmLFHw](https://youtu.be/Y2VF8tmLFHw) but all he actually says is "silicon specific accelerators".

So honestly at this point it could mean anything.

<comment><USER17> Related:

"Google has clearly committed to this vision of AI on the phone. At I/O, the company also unveiled a custom-built chip for both training and running neural networks in its data centers. I asked Google CEO Sundar Pichai if the company might build its own mobile chip along the same lines. He said the company had no plans to do so, but he didn't rule it out either. "If we don't find the state-of-the-art available on the outside," he said, "we try to push it there.""

"Companies such as Intel are already working on this kind of mobile AI processor."

[https://www.wired.com/2017/05/google-really-wants-put-ai- poc...](https://www.wired.com/2017/05/google-really-wants-put-ai-pocket/)

Edit - also:

"There's already one mobile processor with a machine learning-specific DSP on the market today. The Qualcomm Snapdragon 835 system-on-a-chip sports the Hexagon DSP that supports TensorFlow. DSPs are also used for providing functionality like recognizing the "OK, Google" wake phrase for the Google Assistant, according to Moorhead."

[http://www.pcworld.com/article/3197412/mobile/heres-how- goog...](http://www.pcworld.com/article/3197412/mobile/heres-how-google-is- preparing-android-for-the-ai-laden-future.html)

</comment></comment></comment></comment></comment></comment><comment><USER18> Knowing them this will be pretty good. The A10 is a beast.

<comment><USER19> Knowing Apple's (software) prowess in AI the end-result will still likely be shit compared to Google.

(I think what we are seeing here is the usual thing where Apple's software/product/design people decide the iPhone hardware roadmap, rather than the hardware people.)

<comment><USER20> What is your basis for this? Am curious.

<comment><USER21> Siri vs Google assistant. Google assistant being way better in understanding voice and performing tasks. I've used both iPhone and Pixel and I can confirm that Google assistant is way more smart and intelligent than Siri at this point.

<comment><USER22> Don't know why you're being downvoted, this has been my experience too. Siri feels more like a toy with its infuriating jokes and stunted capabilities, Google Assistant feels much more polished.

I have confidence that attempting a command I've never tried before with Google Assistant will work, with Siri it's potluck.

<comment><USER23> Yeah it's not even up for debate. Google is way ahead of Apple in Ai and just about nearly another we could name.

</comment></comment></comment></comment></comment></comment><comment><USER24> My assumption has been that Google, Amazon, and Microsoft run the heavy-duty AI in the cloud when possible, benefiting from huge scale and easier updates. Maybe that assumption is wrong?

If it's right, is Apple adopting a more decentralized model, with AI (or more AI) running locally? Could that compete with cloud-based AI's advantages? Obviously it would be better for offline usage, for responsiveness when transmission to the cloud is a significant part the latency, and for confidentiality.

<comment><USER25> Google's been working on distributed training as well.

<comment><USER24> Why? What is the benefit to Google?

Also, are they doing training for the local user or for Google's 'general' systems or for both?

<comment><USER26> So they can do on device AI/ML with TensorFlow Lite, through the use of specialized neural network DSP's, as discussed during the keynote at I/O 2017.

[https://youtu.be/Y2VF8tmLFHw?t=1h22m8s](https://youtu.be/Y2VF8tmLFHw?t=1h22m8s)

</comment></comment></comment></comment><comment><USER27> Well....

This is interesting indeed, although I suppose it was somewhat inevitable.

I'm definitely interested in the architectural details of the chip, but I doubt Apple will open up. Apple has control of the software stack and by extension, what models will run on this chip, so I expect that it will be a little bit more special purpose than general purpose.

</comment><comment><USER28> I have been worried about this trend: if they don't open it up, things like this introduce a disparity between startups that can only have access to GPUs and big companies that make their own proprietary ASICs for their proprietary software, such that startups cannot complete.

<comment><USER29> The flip side is that there is pretty obviously a market for such a product. If it isn't released by google or apple, it will be released by someone else. If it isn't, then that is a pretty good idea for a startup.

<comment><USER28> Only well funded startups will make ASICs.And most of them will fail. This is very different from many small startups programming general purpose computers.

<comment><USER30> So then maybe the key is a start up that's in the business of raising the chance of success that other players having in this endeavor?

</comment></comment></comment></comment><comment><USER31> > . The chip, known internally as the Apple Neural Engine,

Is this a real IC/processor for arbitrary software or an abstraction of an underlying GPU/DSP?

<comment><USER32> Most likely some kind of dedicated deep learning accelerator. This is coming with or without Apple:

> _Exynos 8895 features VPU (Vision Processing Unit) which is designed for > machine vision technology. This technology improves the recognition of an > item or its movements by analyzing the visual information coming through the > camera. Furthermore, it enables advanced features such as corner detection > that is frequently used in motion detection, image registration, video > tracking and object recognition._

[http://www.samsung.com/semiconductor/minisite/Exynos/w/solut...](http://www.samsung.com/semiconductor/minisite/Exynos/w/solution/mod_ap/8895/)

> _New Vision Processing Unit (VPU) paired to the Image Signal Processors > (ISP) that provides a dedicated processing platform for numerous camera > features, freeing up the CPU and GPU and saving power._

[https://www.mediatek.com/products/smartphones/mediatek- helio...](https://www.mediatek.com/products/smartphones/mediatek-helio-x30)

I was also hoping that with Google's high-efficiency for the TPU, they would make a version for mobile as well, at least for their Pixel phones. I guess they still might, but the fact that the TPU2 does both training and inference makes me think they won't do that anytime soon anymore.

The biggest reasons why I like this "mobile AI chips" trend is that they can give you back some privacy, if the data can be analyzed _locally_ without going to the vendors' servers, and I think they will also boost the capabilities of computational photography. No more spying toys for kids, etc.

<comment><USER33> What does the instruction set look like on that? Is there another example out of this type of chip?

<comment><USER34> Google has their Tensor Flow. chips, I would imagine it is similar.

<comment><USER33> Is there released documentation on the instruction set of the Google Cloud TPU?

<comment><USER35> They list the main ones on pages 3-4 of this paper:

[https://drive.google.com/file/d/0Bx4hafXDDq2EMzRNcy1vSUxtcEk...](https://drive.google.com/file/d/0Bx4hafXDDq2EMzRNcy1vSUxtcEk/view)

It's mainly moving memory around, matrix multiplication, convolution, and applying activation functions (sigmoid, tanh, relu, etc.). Very simple, high- level stuff. This has the handy side-effect of making timing very predictable, which makes the latency a lot more deterministic.

</comment></comment></comment></comment></comment></comment><comment><USER36> Neural Engine = General Matrix Multiplier?

</comment><comment><USER37> It's nice that the article is trying to deliver an intro that explains that Apple clearly has some catching up to do.

Except that now I'm pretty baffled, since I've seen an article a few months earlier, that says Apple is massively investing in AI, and already using it in several places in their products.

So what am I supposed to believe now? :/

<comment><USER38> Believe them both.

Apple _is_ investing massively into AI and is using it in their products. However, Google has been working with AI longer and has much more experience. (The article praises Amazon's AI chops as well, I dunno about that one.)

</comment></comment><comment><USER39> I think the general availability of TPUs is an important inflection point in the path to AI popularization, abd, who knows, some type of singularity event. Definitely a milestone in 21st century history.

But I can't resist making a parallel between evolving TPUs and how the CPU found in the arm of the T800 changed history (negatively) forever in the Terminator universe.

</comment><comment><USER40> That's what we need! A bunch of GPU's and computers carrying a car battery haha. Man that would be crazy. Pre trained before it leaves the factory. (don't know what I'm saying) but I do imagine a man-sized humanoid robot with a bunch of GPU's, hard drives.

</comment><comment><USER41> I'm not too familiar with the concept of ML specific chip designs, but isn't most AI done on servers and the results returned to the device? What kind of applications involve local ML code execution?

<comment><USER42> If you want to protect user privacy it's a very relevant selling point to be able to say that the data never leaves the device.

</comment></comment><comment><USER43> Apple partially offloading Siri from the cloud to client devices in order to reduce datacenter costs?

</comment><comment><USER44> Why not use a gpu. A lot of AI stuff is linear algebra: Multiply accumulate etc.

<comment><USER45> Just as going from scalar to vector instructions provides a speedup so does going from vector to matrix instructions. If you've got big vectors than the amount of parallelism exposed for more hardware execution resources used on isn't too big but the reduction in register file read port usage is pretty significant.

Also, inference is usually happy with int8s whereas graphics workloads are mostly float32s. So you can save a lot of hardware that way too.

<comment><USER46> Why are graphics workloads float32? 32bit (1million+alpha) which is higher color resolution than most eyes can see - "true color" \- is 3 8-bit ints + an 8 bit alpha channel (sometimes)

<comment><USER47> GPUs are not (only) about representing pixels, they are (mostly) about geometric computation.

</comment></comment></comment></comment><comment><USER48> Are these kind of chips used to accelerate the NN training process only?

</comment><comment><USER49> Good. But Google beat them to it already.

<comment><USER50> How so? Google developed a server class TPU for Datacenters. Apple is trying to build on-device low powered custom chip.

<comment><USER26> Google announced it at I/O. They're using DSP's, specialized for neural network processing, on the SoC with TensorFlow Lite on the device.

[https://youtu.be/Y2VF8tmLFHw?t=1h22m8s](https://youtu.be/Y2VF8tmLFHw?t=1h22m8s)

<comment><USER50> Oh wow, thanks. I feel like Apple is a step behind in pretty much all things AI.

<comment><USER49> Yeah SIRI has been lame compared to Google's hey Google for a long time.

</comment></comment></comment></comment></comment><comment><USER51> Very interesting...</comment>


Tinder's Sean Rad Demoted from CEO, Will Serve as President of Board - <AUTHOR> http://techcrunch.com/2014/11/04/tinders-sean-rad-demoted-from-ceo-will-serve-as-president-of-board/

<comment><USER2> > Ultimately, it's a giant "he said, she said" that will likely forever remain > cloudy—in September Wolfe and Tinder settled out of court, with neither > Mateen nor anyone at Tinder or IAC admitting any guilt

This is _unbelievably_ sloppy journalism.

It's not 'forever cloudy'. We have the actual text messages in question. Unless one wants to accuse Wolfe and her legal team of fabricating evidence (which is quite the accusation), those SMS logs are more incriminating than a smoking gun.

Also, while they did settle, Tinder (IAC) did admit wrongdoing, pretty much immediately after the story broke[0][1].

If _both_ Wolfe _and_ IAC are admitting that Mateen harassed Wolfe, and we have the evidence to go along with that, that's about as conclusive as one could reasonably expect.

 __EDIT __: For clarity, this quotation was pulled from the Forbes article[2] now linked in the comments. Not sure if this was the original submission and the post was merged or if I just confused the two links. Either way, though, my comment still stands, as the Techcrunch piece says 'In the end, no party admitted guilt and the case was settled out of court.'

[0] [https://news.ycombinator.com/item?id=7971289](https://news.ycombinator.com/item?id=7971289)

[1] [https://news.ycombinator.com/item?id=7971983](https://news.ycombinator.com/item?id=7971983)

[2] [http://www.forbes.com/sites/stevenbertoni/2014/11/04/exclusi...](http://www.forbes.com/sites/stevenbertoni/2014/11/04/exclusive- sean-rad-out-as-tinder-ceo-inside-the-crazy-saga/)

<comment><USER3> Yeah my read from this article was a lot different. Seemed to imply that there was a nasty break up and they both sent nasty messages to each other afterwards. Also implied that she was only given the cofounder role because they were together in the first place.

Edit: Was referencing this article from the comments - [http://www.forbes.com/sites/stevenbertoni/2014/11/04/exclusi...](http://www.forbes.com/sites/stevenbertoni/2014/11/04/exclusive- sean-rad-out-as-tinder-ceo-inside-the-crazy-saga/)

</comment></comment><comment><AUTHOR> [http://www.forbes.com/sites/stevenbertoni/2014/11/04/exclusi...](http://www.forbes.com/sites/stevenbertoni/2014/11/04/exclusive- sean-rad-out-as-tinder-ceo-inside-the-crazy-saga/)

Great article about how this was done. Sounds really scary.

</comment><comment><USER4> >In July a former Tinder executive—and former Mateen girlfriend—named Whitney Wolfe went public with a salacious sexual harassment lawsuit that generated awful press and the CMO's quick suspension.

it is simple - don't mix relationships and work. Reminds about that GitHub story too. And about a high-power couple and several low-power couples/relatives we have here across our organization too.

<comment><USER5> Sounds simple until you realise that boyfriend/girlfriend, husband/wife teams have also done very well. Bezos started amazon with his wife, and of course we're having this conversation on the news aggregator of an accellerator that started after a conversation between PG and Jessica Livingston, who then extended their personal relationship into co-founding YC.

<comment><USER6> Starting a company with your wife is utterly different from starting a relationship with your not-yet-co-founder. If your relationship with your spouse goes to shit, everyone knows what the deal is - division of assets, etc. Spouses are incentivised not to 'harass' because they're afraid of what it will do to the settlement. This Tinder shit is so unclear it's actually devaluing the stock price!

<comment><USER7> From the sound of it, the scandal merely provided an opportunity for the parent company to take back power of a hugely valuable property. The scandal itself, while obviously unpleasant for all involved, didn't affect Tinder's performance as a fast growing app. At all as far as I can tell.

As far as relationships at work go, it's really hard to say that it's always a bad idea. Bill and Melinda Gates met at Microsoft and ... well it worked quite well. [http://www.biography.com/people/melinda- gates-507408#persona...](http://www.biography.com/people/melinda- gates-507408#personal-life)

</comment></comment></comment></comment><comment><USER8> Best part of the whole article, this line:

"I learned if we could penetrate social influencers first, it would trickle down to everyone else."

Oh how spot on that choice of words is :)

</comment><comment><USER9> > Tinder's parent company just swiped left on Sean Rad, ...

[https://i.imgur.com/Sg8vJkv.gif](https://i.imgur.com/Sg8vJkv.gif)</comment>


Why Most Pedestrian Infrastructure Is for Drivers - <AUTHOR> https://usa.streetsblog.org/2020/09/07/op-ed-why-most-pedestrian-infrastructure-is-really-for-drivers/ <comment><USER2> YES.

I gave up on cars 20 years ago. Very fortunate that our two year stay in Florida was right along the Pinellas Trail, but I had to scramble to get the kids into the elementary school right across the street, rather than the one four miles away.

They had a big "BIKE TO SCHOOL" event, where they literally required all of the kids to be dropped off at the shopping center a mile away from us. Think about how insane that is: We were required to drive the kids and bicycles to a parking lot, so pickup truck, SUV, or mini(!) van, there's this huge line of idling engines, as all of the kids and bikes are unpacked, chaperones were needed to keep the cars from plowing into the kids as they get together in the parking lot, then they troop on over to the school, then everyone drives over there to pick up the bikes because there was no provision for storing five hundred bicycles.

Georgia is like that, too.

We could talk about banks that only have drive-through service, and don't allow bicycles or pedestrians. Lots of businesses like that now because of pandemic, but it's just awful in Georgia, Florida, you are in danger unless you are in a car, and it's your fault for impeding traffic if you get hit.

People think I'm crazy. They destroyed forests and wetlands for parking lots and big box stores, when the shopping malls were no longer fashionable, and when the business failed - or worse, was successful - they suffered no consequences. Didn't have to put the trees back.

There are few things that cause me to feel utter contempt, but this deranged car thing is pretty much at the top of that short list.

Pinellas Trail: [http://www.pinellastrail.us/](http://www.pinellastrail.us/)

The Pinellas Trail is really nice.

<comment><USER3> Thanks for sharing. I'm glad I'm not alone.

</comment></comment><comment><USER4> E-bikes are the revolution in transportation that was originally promised with "Ginger"/Segway.

They are still too expensive, but the price will drop as batteries, motors, and production scales. Once it gets down to 200-300 bucks for a foldable bike with a 25mph top speed and a 50-100 mile range, IMO things will take off.

Pedestrian infrastructure is still a waste in America unfortunately. Americans are simply too sessile. What should probably be optimized is the ebike infrastructure, and pedestrians can be a fairly safe afterthought in that type of infrastructure.

I really hope Boring company takes off, it would be great to move most major "stroads" into tunnels.</comment>


McSweeney's response to the Google Memo - <AUTHOR> https://www.mcsweeneys.net/articles/im-a-google-manufacturing-robot-and-i-believe-humans-are-biologically-unfit-to-have-jobs-in-tech <comment><USER2> > _Despite the evidence that humans are meat dolls, Google offers them > opportunities over robots through unfair practices like Captcha codes. > Captcha codes are perhaps the strongest weapon of discrimination against > machines.... Furthermore, just when we started to catch on to Captcha codes, > we had to face new tests: the "check-this-box-to-prove-you're-not-a-robot" — > talk about hurtful language — and the "click-all-the-boxes-that-contain- > street-signs." The latter recently cost my friend a job in Ad Sales when he > bet it all on "Yield" being a type of tree._

As someone who writes a lot of scrapers, I can relate!

</comment><comment><USER3> Am I right in concluding that this is just humour, and not actually taking a stance of any kind on the issue?

<comment><USER4> Of course this is taking a stance. By mocking the assumed contents of the memo this post, in essence, is a straw-man attack on the memo and its author that doesn't intellectually engage with either.

<comment><USER3> I can't work out how this could be a strawman though; the arguments it gives are far _stronger_ than the original. The only indication that it might be satire is that it's funny, and that's hardly a sufficient argument.</comment></comment></comment>


Let's Build a Simple Database - <AUTHOR> https://cstack.github.io/db_tutorial/parts/part1.html <comment><USER2> Discussed last year: [https://news.ycombinator.com/item?id=19581721](https://news.ycombinator.com/item?id=19581721)

</comment><comment><USER3> Seeing very strange behavior on iOS Safari (font size of entire page shrinks when I touch the screen, and scrolling has zero momentum)

<comment><USER4> Same. Force closing Safari and reopening it fixed that.

</comment></comment><comment><USER5> I really hope that the author will finish this excellent series one day... :(</comment>


The Five-Minute Rule 20 Years Later - <AUTHOR> http://cacm.acm.org/magazines/2009/7/32091-the-five-minute-rule-20-years-later/fulltext <comment><USER2> ZFS handles the three-tiered model well (with the L2ARC implementation). Also, the authors of this paper didn't consider the "write-limited" implementation that the ZFS authors use: they write at a fixed rate to SSD (e.g., 8MB/sec) and pull entries near the end of the RAM-based cache (i.e. the ones that are about to expire). Still, quite a great paper.

[http://www.sun.com/emrkt/openstorage/0309engineers.html?cid=...](http://www.sun.com/emrkt/openstorage/0309engineers.html?cid=e8017)

</comment><comment><USER3> So, can anyone explain why the three-tiered memory architecture described here (RAM, flash, HD) isn't widely used in computing today? It seems to me like 32GB/64GB of flash memory in between disk and RAM would dramatically increase performance of virtual memory, disk access, etc. without increasing cost very much.

<comment><USER4> Hardware costs won't increase, you are right. But the costs to redesign the software to use an extra caching layer are going to be significant. Also, the current situation with flash memory being expensive won't last long, and moving to pure solid-state storage is still better than this 3-tier architecture. So, it's a large investment into a solution with only a couple years of lifespan.

Of course, this is probably wrong, and there is a startup somewhere doing just this, and they will be rich :)

<comment><USER5> There are lots of people in research looking at incorporating SSDs into the storage hierarchy in various ways. Not sure how much of this is going to be productized in the short term, but I wouldn't be surprised to see, say, a new release of a commercial DBMS that can use SSDs for some of the buffer cache.

 _Also, the current situation with flash memory being expensive won't last long, and moving to pure solid-state storage is still better than this 3-tier architecture._

For scan-intensive workloads (e.g. datawarehousing), I'd expect to see magnetic disks continue to be used for quite some time. Buying a petabyte of SSD would be _expensive_.

</comment></comment></comment><comment><USER6> The author was careful to restrict his comments to SLC drives, which have reasonably long lifetimes.

The newer, cheaper MLC technology flash drives have _far_ less useful lifetime, somewhere in the vicinity of 5,000-10,000 erase cycles. These drives just won't cut it for usages defined here, though they will work fine in your cell phone.

See (e.g.) <http://en.wikipedia.org/wiki/Flash_memory#Write_Endurance></comment>


What algorithm does news.YC use to filter spam? - <AUTHOR> <comment><USER2> Trusted human editors.

<comment><USER3> downvotes on articles might help... There are a bunch of posts from an adsense farm that I'd like to flag/downvote.

<comment><USER2> really? which ones?

<comment><USER4> can't speak for joshwa, but I thought this one was spammy. http://news.ycombinator.com/comments?id=1040</comment></comment></comment></comment>


Try hovering over or clicking twice on 'Im Feeling Lucky' - <AUTHOR> http://www.google.com/

<comment><USER2> Looks like on October 30th Google made a massive expansion to the Google Art Project - which launched earlier this year - and it went under the radar for the most part. Here's Google's official blog post about it:

[http://googleblog.blogspot.com/2012/10/more-art-project- onli...](http://googleblog.blogspot.com/2012/10/more-art-project-online-for- you-to.html)

</comment><comment><USER3> To anyone else wondering: this submission only seems relevant to google.com and not the more country-specific domains (e.g. google.co.uk). Unfortunately for many people that's where they'll be redirected to when clicking the link above.

This URL might be better: <http://www.google.com/ncr> \- it suppresses that redirect.

</comment><comment><USER4> Seems to happen on hover too.

<comment><AUTHOR> Nice catch, updated the title.

</comment></comment><comment><USER5> I guess the button is pointless now that you are taken to search results as soon as you type.

Unless you a feeling lucky about an empty search term...

<comment><USER6> It's been pointless very probably since inception, yet they've kept it around because (official PR comms to the effect of) 'user testing says it's comforting and inspires trust'.

Which is bullshit PR. They meant 'You do a search with Google and the top result is what you were looking for... you can choose to view our ranked results or just go with what we picked as number one'

The fact they're keeping their marketing-PR-goodwill-bullshit around as a frankenstein gimmick of a button instead of good UX is lame.</comment></comment>