TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Ask HN: How does high quality source code from Google looks like?

7 pointsby andygrunwaldover 4 years ago
There is a lot of content out there regarding high-quality source code to write maintainable and clean code. This is not what I am looking for.<p>Every now and then, I read answers from Ex-Google Engineers on questions like &quot;How is it like to be out of Google? What do you miss in the industry?&quot;. Often they say &quot;the quality of source code&quot;.<p>I am curious: What is that special to the source code inside Google? What makes them &quot;high quality&quot;? Is it a well-commented code base? That people with less context get a grasp of what the piece of code is doing? Is it a strict following of company-wide coding guidelines? Is it the tooling around that supports the maintenance of the quality?<p>I am curious to hear answers from people who have experienced the code inside Google. And maybe have concrete examples?<p>Thanks all.

4 comments

tonyover 4 years ago
Go to <a href="https:&#x2F;&#x2F;github.com&#x2F;google" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;google</a>, but sort by language:<p>- C: <a href="https:&#x2F;&#x2F;github.com&#x2F;google?q=&amp;type=&amp;language=c" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;google?q=&amp;type=&amp;language=c</a><p>- C++: <a href="https:&#x2F;&#x2F;github.com&#x2F;google?q=&amp;type=&amp;language=c%2B%2B" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;google?q=&amp;type=&amp;language=c%2B%2B</a><p>- Go: <a href="https:&#x2F;&#x2F;github.com&#x2F;google?q=&amp;type=&amp;language=go" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;google?q=&amp;type=&amp;language=go</a><p>- Java: <a href="https:&#x2F;&#x2F;github.com&#x2F;google?q=&amp;type=&amp;language=java" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;google?q=&amp;type=&amp;language=java</a><p>Google&#x27;s style guides: <a href="https:&#x2F;&#x2F;google.github.io&#x2F;styleguide&#x2F;" rel="nofollow">https:&#x2F;&#x2F;google.github.io&#x2F;styleguide&#x2F;</a><p>Hand-picked: <a href="https:&#x2F;&#x2F;source.chromium.org&#x2F;chromium" rel="nofollow">https:&#x2F;&#x2F;source.chromium.org&#x2F;chromium</a>, <a href="https:&#x2F;&#x2F;android.googlesource.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;android.googlesource.com&#x2F;</a>, <a href="https:&#x2F;&#x2F;fuchsia.googlesource.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;fuchsia.googlesource.com&#x2F;</a><p>Filter by subject: <a href="https:&#x2F;&#x2F;opensource.google&#x2F;projects&#x2F;explore&#x2F;featured" rel="nofollow">https:&#x2F;&#x2F;opensource.google&#x2F;projects&#x2F;explore&#x2F;featured</a><p>Also you can do the same for <a href="https:&#x2F;&#x2F;github.com&#x2F;microsoft" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;microsoft</a> and <a href="https:&#x2F;&#x2F;github.com&#x2F;facebook" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;facebook</a>
rwdimover 4 years ago
See for yourself :) <a href="https:&#x2F;&#x2F;github.com&#x2F;golang&#x2F;go" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;golang&#x2F;go</a><p>This is a good example file:<p><a href="https:&#x2F;&#x2F;github.com&#x2F;golang&#x2F;go&#x2F;blob&#x2F;master&#x2F;src&#x2F;crypto&#x2F;crypto.go" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;golang&#x2F;go&#x2F;blob&#x2F;master&#x2F;src&#x2F;crypto&#x2F;crypto.g...</a>
评论 #24931760 未加载
Wonnk13over 4 years ago
I think it says a lot more about how strict the readability standards are for submitting stuff to corp&#x2F;production. Even code written by a moron by me looks decent after code review.
bjourneover 4 years ago
Find out for yourself by studying Cromium&#x27;s, TensorFlow&#x27;s or V8&#x27;s source code. It&#x27;s all available online. Most of the code for Android is too.