Goodreads helps you keep track of books you want to read.
Start by marking “If Hemingway Wrote JavaScript” as Want to Read:
If Hemingway Wrote JavaScript
Enlarge cover
Rate this book
Clear rating
Open Preview

If Hemingway Wrote JavaScript

4.15  ·  Rating details ·  297 ratings  ·  54 reviews
What if William Shakespeare were asked to generate the Fibonacci series or Jane Austen had to write a factorial program? In If Hemingway Wrote JavaScript, author Angus Croll imagines short JavaScript programs as written by famous wordsmiths. The result is a peculiar and charming combination of prose, poetry, and programming.

The best authors are those who obsess about lang
...more
Paperback, 200 pages
Published October 23rd 2014 by Penguin Random House LLC (No Starch) (first published August 25th 2014)
More Details... Edit Details

Friend Reviews

To see what your friends thought of this book, please sign up.

Reader Q&A

To ask other readers questions about If Hemingway Wrote JavaScript, please sign up.

Be the first to ask a question about If Hemingway Wrote JavaScript

Community Reviews

Showing 1-30
Average rating 4.15  · 
Rating details
 ·  297 ratings  ·  54 reviews


More filters
 | 
Sort order
Start your review of If Hemingway Wrote JavaScript
عمرو صبحي
Jan 10, 2015 rated it it was amazing
Follow your heart, but take Javascript with you.
Patrick
Dec 03, 2014 rated it did not like it
Bravo to the author of this book for successfully acquiring my money.

I didn't know what to expect with this book, but I suppose it is pretty much summed up by its title. You won't learn programming from this book and you won't get any deep insights about the featured authors.

Instead of reading this book, I would recommend looking at the list of authors who are featured in this book and getting one of their books. Hardcover would be preferable, and something substantial like Joyce's
...more
Jigar Brahmbhatt
Jan 11, 2017 rated it really liked it
This book is an exciting exercise. It is very amusing to see the authors code, and amusing still to know that Angus Croll is quite well versed in both coding as well as literature to pull off an idea like this. The analysis of style he provides per writer is bang on. When asked to produce a Fibonacci series for a given "n", Hemingway produces the most essential, no-nonsense code (not an extra line or variable anywhere), while Andre Braton, the surrealist, defines an array of indefinite length an ...more
Dan
Oct 24, 2014 rated it it was amazing
Shelves: literary, programming
A unique genre, all it's own: literary programming books.

Here we have a survey of 25 authors, along with a JavaScript programming problem written using code in the style of that author. Croll provides a short biography of each author, a code snippet, and then some explanation of why the snippet was written the way it was.

Lots of fun and JavaScript in-jokes, but also a thoughtful exploration of the flexibility of JavaScript and some of it's more esoteric elements. Also, might even teach you a f
...more
Rob
Aug 21, 2014 rated it it was amazing
Reading this book, I am reminded first of my friend Mike. Of an evening in Baltimore at a mutual friend's home. Of vodka consumed and books given conversational chase and perhaps not a small amount of hero-worship on my part as he accelerated into his chosen field and I languished behind a copy machine at the worst-performing Kinko's in the country. [^1] House of Leaves may have been involved.

And I am reminded of my friends David and Jeffrey. Of our many lunches together and how they wou
...more
Stephanie
Mar 14, 2016 rated it really liked it
as I was reading this, I thought to myself that this book is probably the only programming book out there right now that I can read in less than two weeks (and I did end up finishing it in less than two weeks). this fact reminds me that I'm still way more interested in writing and expressing than grammar (of both programming and non-programming languages), although I often wish it was the other way around. I usually try to read a programming-related book and a non-programming related-book (usual ...more
Zach
Mar 18, 2016 rated it liked it
I loved this book at first--it seemed written especially for me, and I laughed out loud a number of times. Croll is an excellent writer, and he shows a deep love and appreciation for both literature and javascript. Many of the code samples are ingenious, and I usually learned a thing or two from each example. But too many code samples don't really work. They bear only a superficial relationship to how I'd imagine a writer might code, such as by using variable names from character names in an aut ...more
Jean-Luc
Jan 06, 2016 rated it it was amazing
Pick your favorite author, pick your favorite JavaScript interview question, then throw the 2 together. The result is delightful. It is known that computer programming is a science, but it's also an art, and rarely have the two facts been conjoined so lovingly.

You do not need my recommendation. Brendan Eich, the creator of JavaScript, said the book is cool. Marijn Haverbeke, author of Eloquent JavaScript, loved it.

Only 3 of the authors profiled were alive @ the time the book was published. That may be because only the
...more
Cole Simmons
Apr 07, 2015 rated it liked it
Because everything can be done in so many different ways, JavaScript is very reflective of the writer. Croll beautifully displays this by showing what various programs would look like if written by different authors. In total, 25 different authors - from J.K. Rowling to Lewis Carroll - are divided up among 5 different programs. Background is given for each author, and it is explained why their code would look like it does. Many of the programs are almost unintelligible - especially for the autho ...more
Piyali Mukherjee
Jun 27, 2016 rated it it was amazing
Recommends it for: coder-writers
To say that I love this book is an understatement. A collection of the best authors of our time writing JavaScript solutions to basic CS problems, this book does not fail to delight. Special mention to
-> Shakespeare: declares variables as dramatis personae and ends loops with exeunt
-> Sir Arthur Conan Doyle: Ends recursions with "whatever remains, no matter how improbable must be the truth"
-> Jane Austen: Equality comparisons with "It is a truth universally acknowledged tha
...more
Thaw
Aug 29, 2015 rated it it was amazing
The combination of literature writer style and coding is so much fun. It can give u laugh, wonder smile and fun.
Marissa
Books that combine classic-literature humor and programming-language humor are obviously meant for a niche audience, but as a longtime literature obsessive who recently learned how to code, I am presumably the reader Angus Croll had in mind for If Hemingway Wrote JavaScript. Still, I’m not yet at the point where “clean,” standard JavaScript (the kind Ernest Hemingway would write) is fully intuitive to me, so I kind of wish I’d waited to read it.

The book consists of 25 brief JavaScript programs written in the style
...more
Devin
Jun 22, 2017 rated it it was amazing
This is what happens when a love for language in its most literary sense spills over into programming syntax. And the the oddities of Javascript lends itself well to these algorithmic flights of fancy. Angus Croll's passion for reading and Javascript are hard to miss. The illustrations are brilliant and the material providing background on each writer (Ernest Hemingway, David Foster Wallace, Jane Austin, Lewis Carroll, Tupac, etc.) is fantastic. I wanted to understand more about higher order fun ...more
Elijah Fry
May 10, 2019 rated it it was amazing
You need JavaScript familiarity to get this book.

That’s said, for such a niche market, this is a work of art. It’s absolutely hilarious and dances the knife’s edge between pretentiousness and flippancy. I found myself getting upset at the supposed authors for writing the JavaScript the way they did, it was very convincing and the commentary is priceless.
Sweemeng Ng
Mar 16, 2017 rated it it was amazing
While I don't recommend using some of the codes in the book in production, it does surprise me with the way code can be written in javascript.

The code is not always good, but it is always interesting.
Mehmet
Sep 29, 2017 rated it it was amazing
Amazing. It's the first software book doesn't make me open a code editor, and It's the first non-software book contains code blocks inside. Cool.
Jerry Yoakum
Apr 17, 2018 rated it really liked it
Shelves: read-some
A fun book that mixes literature with programming by examining JavaScript written in a style that is similar to various authors. Much funnier if you have read books by the discussed authors.
Stephen Bennett
Mar 23, 2018 rated it it was amazing
A very clever and witty book that brings together two, what initially appear as fairly disparate, topics in a easy to read way. It also showed me how little I know of JavaScript!
Agarbarino
Jun 21, 2017 rated it really liked it
Enjoyable. This was a gift and it was well chosen. I found it light hearted, comical and yet oddly educational. It makes me smile to think a twitter programmer wrote this.

Well done.
Thiago
Oct 25, 2018 rated it it was ok
Original idea. Funny. But the book doesn't add too much.
Wojtek Ogrodowczyk
Dec 26, 2016 rated it it was amazing
I loved reading this book. However, it requires you to have a basic understanding of JS syntax and programming patterns, and some basic literary knowledge, to fully enjoy it. If you do, it's a pleasant evening read of a beautifully designed book.

You might even learn a new trick or two!
Javier
Sep 12, 2014 rated it it was amazing
if Hemingway wrote JavaScript is a labour of love; of love for literature, for Javascript and for programming at large.
Much like Fernando Pessoa's heteronyms, Angus Croll manages to put himself in the shoes of some of the most famous writers in the history of western literature and answer a strange question: how would they write JavaScript?
Now, needless to say that finding the answer to that question wouldn't be possible without the ludic spirit of the author and a healthy disregard for the mor
...more
Tom Spruce
Mar 09, 2016 rated it really liked it
"If Hemingway Wrote JavaScript" is a whirlwind tour of the literary world and a creative exploration of JavaScript code. Even a non-programmer can enjoy the first half of content in this book by ignoring the code portion.

As a seasoned coder, it's best to restrain yourself during the introduction where the author preaches the looseness of JavaScript as some sort of creative virtue. I could be writing my own essay in counter to the author, but it's not appropriate.

The JavaScript here is not mean
...more
Cihan Koseoglu
Feb 09, 2017 rated it really liked it
I think it was really funny, the whole thing can be finished under an hour, I skipped like 4-5 author examples, of authors I did not really know, but the book was fun.
Arensb
Sep 13, 2016 rated it really liked it
Shelves: humor, geekery
If you’re not a programmer, you’re not this short book’s target audience. But if you think that programming and software engineering are straightforward linear sequences of “find problem, solve problem”, with no creativity, fun, or poetry, then you ought to at least borrow it at the library, and see for yourself that there are many ways a problem can be solved.
If you are a programmer, then you know that there’s creativity involved, and will appreciate how Croll translates various authors’ qui
...more
Matt
Dec 03, 2014 rated it liked it
A neat idea and a nice bundle of literary lore for folks who may or may not have a lot of exposure.

It could use more thorough comparisons. Also, it would be nice if more of the approaches had value. There were times when I was like, "oh lord no." over the code when I really appreciate the writing of the proposed author.

I think the study of code as literature has merit and that in the future I hope we'll all be reading better code because its writer was influenced by the greats. I kn
...more
Alasdair Craig
Oct 02, 2015 rated it it was amazing
Shelves: programming
I was expecting something completely whimsical. Instead I found it quite brilliant, so clever and creative with laugh out loud moments. With informative introductions to the various writers and their written style, I found myself reading up about books and authors that sound intriguing. I'm so impressed by the creativity of author Croll in thinking this out, and also impressed by the Javascript language for the variation in structure and expressiveness it allows, as wonderfully "demonstrated" by ...more
Victor
Aug 21, 2016 rated it really liked it
This is quite a good exposure book to the literary world for developers. Has valid javascript written in queer ways depending on the author. It is a good change in perspectives, not really practical, but theoretical. It exposes the different writing styles of the author in a way that is relatable to me as a programmer, an author of codes.

Overall would recommend to those who have feet in both the lit world and the programming world. But then, I may be biased because I feel all authors
...more
Roman
Dec 29, 2014 rated it it was amazing
Shelves: read-novels, on-shelf
Bending javascript in all possible and impossible ways, this book makes you smile, wonder and laugh (in any order) to finally leave you surprised or not, over the code served in the style of famous writers. Another contribution of this great book to the world of literature could be to make you curious to read some of the authors' masterpieces, if you didn't do that yet.
Hazel
Aug 24, 2016 rated it really liked it
Javascript aside, the Angus Croll gives an excellent analysis of notable writers' and poets' writing style and personality. Each writer conveys their unique approach of writing a javascript exercise. It was fun reading each and a few even gave me a chuckle (William Shakespeare, Dan Brown, Franz Kafka).
« previous 1 next »
There are no discussion topics on this book yet. Be the first to start one »

Readers also enjoyed

  • Functional JavaScript: Introducing Functional Programming with Underscore.js
  • High Performance JavaScript
  • Developing Backbone.js Applications
  • JavaScript Allongé: A strong cup of functions, objects, combinators, and decorators
  • JavaScript Patterns
  • Learn you some Erlang for great good!
  • Basic Category Theory for Computer Scientists
  • Concepts, Techniques, and Models of Computer Programming
  • Introduction to Functional Programming
  • The Reasoned Schemer
  • LISP in Small Pieces
  • Learning Android
  • Realm of Racket: Learn to Program, One Game at a Time!
  • Effective JavaScript: 68 Specific Ways to Harness the Power of JavaScript
  • Programming Ruby: The Pragmatic Programmers' Guide
  • Let Over Lambda
  • Dependency Injection in .NET
  • Interactive Data Visualization for the Web
See similar books…

Goodreads is hiring!

If you like books and love to build cool products, we may be looking for you.
Learn more »