The document discusses the challenges of reading and understanding code written by others. It notes that while writing your own code from scratch makes it very clear, working with others' code can be confusing as it is unfamiliar. It provides examples of code snippets to illustrate what unfamiliar code may look like and emphasizes the importance of carefully reading and assessing others' code to understand it.
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Reading Code You Didn't Write
1. Reading Code You Didn't Write
A lightning talk.
August 20, 2015 mikailawaters@gmail.com
2. mikailawaters@gmail.comReading Code Your Didn't Write - A lightning talk.
Writing most of your apps from scratch can mean your code
looks like this to you.
SO FRESH AND SO CLEAN
5. How to dig in - suggested hack leveraging knowledge of the
product workflow to navigate uncertainties in the code.
Build a workflow map - figure out
how the code works at a high level.
Select a component of the workflow - get familiar with the
code around that component, what files are involved, and how they
work together.
Use search to get really specific - find a
snippet and use Cntrl Shift F in sublime to search all files
for that piece.
I located this partial buried deep in our code by looking
for “Type a comment.”
mikailawaters@gmail.comReading Code Your Didn't Write - A lightning talk.
A B C D1
D2
D2
E
6. One person drives while the other navigates.
Pair Programming
mikailawaters@gmail.comReading Code Your Didn't Write - A lightning talk.
7. Hackathons
Great for meeting people, and you can get really specific about the content.
mikailawaters@gmail.comReading Code Your Didn't Write - A lightning talk.
8. Also a great place to start meeting other people who are interested in the same
work as you - civic tech, ed tech, polymer, node.js, sandwich eaters.
Meetups
mikailawaters@gmail.comReading Code Your Didn't Write - A lightning talk.
9. Reading Code Your Didn't Write - A lightning talk.
Open source projects
A great opportunity to learn something specific - so if you’re interested in a
specific company’s work, check out a specific workflow
mikailawaters@gmail.com
10. Open source projects
Or if you’re interested in learning a specific framework or language
mikailawaters@gmail.comReading Code Your Didn't Write - A lightning talk.
11. The most important thing is to pick something you’re passionate
about - then you’ll be fully invested in it’s success.
mikailawaters@gmail.comReading Code Your Didn't Write - A lightning talk.
12. Do unto others...
You are now part of a community! If you want to read and work with solid code, you
should write solid code as well. Follow best practices, and read the docs.
mikailawaters@gmail.comReading Code Your Didn't Write - A lightning talk.
13. Put notes in your code
It’s extremely helpful
for you, if you come back to your work
after a few months or even weeks
for others if they’re trying to decipher
why you built something a certain way
when you’re writing public work or API
work, and others are going to check out
your code
if your company uses a documentation
gem
mikailawaters@gmail.comReading Code Your Didn't Write - A lightning talk.
source: xkcd
14. mikailawaters@gmail.comReading Code Your Didn't Write - A lightning talk.
In Conclusion
Reading other people’s code can be a challenge, but start high level and work your
way towards specificity.
Start building a network by pair programming, going to meetups and hackathons,
and working on open source projects.
Write code in a manner that would make it easy for others to understand.
You’ll learn new things, meet new people, and could end up with a new job!