A Googler analyzed a billion files to settle the programming dispute made famous by HBO's 'Silicon Valley'
If you watch HBO's "Silicon Valley," you may remember this now-classic scene from the most recent season, where our hero Richard Hendricks ends his relationship with a Facebook engineer over her programming style:
The debate over tabs and spaces, as presented in HBO's Silicon Valley, is real: Developers have been arguing over using tabs versus spaces for formatting their code for almost as long as the concept of programming has existed. At stake is the aesthetics of the code itself - does putting a tab after each new line make it more readable? Or do you just push the space bar a few times?
(A more detailed explanation of the tabs vs. spaces debate can be found here.)
And so Google Developer Advocate Felipe Hoffa stepped in. By analyzing a billion files, taken from the 400,000 top programming projects on the GitHub social network for software developers, representing 14 terabytes of data all told, he was able to see who was using tabs, and who was using spaces, in most major programming languages.
You can read his full results and methodology here, but the end result is bad news for the tabs-loving Hendricks. Check it out:
As you can see, spaces far outpace tabs in every major programming language with the exceptions of C, one of the very oldest programming languages still widely used, and Google's Go, an upstart of a programming language that's finding fans among people writing software for the server.
This doesn't exactly prove which one is better - but it certainly shows the way that programmers are working in real life. And in most ways that matter, it seems the debate is already over.
- More than $100,000 raised for loyal Burger King employee of 27 years in GoFundMe campaign after video shows him getting 'goody' bag as reward
- 'Get your boy Elon in line:' Former NASA official says she was ridiculed for supporting SpaceX in new memoir
- India is betting on casinos, online games and horse races to fill its coffers
- Pallonji Mistry, the elusive but powerful phantom of Bombay House
- Asus VivoBook Pro 14 OLED review – good performance with a lightweight design
- Ola Electric’s HR Director quits after fourteen months as top executives depart
- Making sense of metaverse – a primer
- Four of every 10 FIIs are from the US; most others are from tax havens