Skip to content

Instantly share code, notes, and snippets.

@dmleong
Created October 20, 2016 20:35
Show Gist options
  • Save dmleong/c124dd95438f477de79e1d77b179afa7 to your computer and use it in GitHub Desktop.
Save dmleong/c124dd95438f477de79e1d77b179afa7 to your computer and use it in GitHub Desktop.

What are some of your favorite software development tools? Is there a tool you would like to learn more about?

2: Describes deeply learning or customizing a tool, discusses trade-offs of, e.g., IDEs versus text editors, or recognizes "typing is not the bottleneck."

Answer:

  • atom bc super modular, can write plugins to change colors
  • grep and gnugrep - other grep is trash, can find files quickly like your initials or 3 lines before or after
  • Follow up question - do you find it easier to use than Atom's native search?
  • There's a native search? Didn't seem particularly interested in finding out too much more - possible problem to look into

Why is it important to write software tests for the systems we build? Can you describe some differences between "unit" tests and "integration" tests? What are the trade offs between those kinds of tests?

1: Discusses the value of regression tests in larger projects, even if they don't always write tests for their own projects.

Answer:

  • Important to write tests bc sometimes your software doesn't do what you want
  • Unit tests test the thing you wrote
  • Integration tests (googles definition of integration test and reads it out loud)
  • Tests as a group
  • When you sample the beer at the end of a tour - sample end to end as opposed to just one section
  • Always write tests unless they're given at the beginning of an assignment
  • Sometimes will write tests or use the Perl debugger

Coding exercise

Direct the candidate to the open Pull Request for User#obfuscated_name. Ask them to implement the solution by getting the failing tests to pass. If they struggle with navigating to the failing test or related implementation code, give them small prompts. If they're not sure how to proceed with User#obfuscated_name due to syntax confusion, ask them to psuedocode a solution first then encourage them to translate it with some help. 3: Moves relatively quickly / independently to the source of the problem and implements the solution without prompting. Pushes a commit up to the PR and leaves a comment.

  • Demonstrated exceptional knowledge of Rails stack
  • Wrote regex to solve the obfuscated name problem and pushed the change with no problem at all
  • Was receptive to feedback about using map instead of each

Once the failing test is passing or they've gotten as far in psuedocode as they can, ask the candidate how well they think this solution solves the problem of allowing anonymity for event attendees. 3: Recognizes the approach still reveals identifiable info and doesn't solve the problem. Describes more a effective approach, such as fully obscuring the names and avatars, or hiding anonymized users behind an "and N more attendees" display.

  • Answered it might be good enough, but could run into collisions if conference is too big
  • Suggested that it would be better to use a hexstring instead and demonstrated how to create a random string

Ask the candidate to view the open issue and attempt to reproduce the bug. 1: Finds the error in question but only after an extended or brute-force search.

  • Candidate knew where to look through extended Rails knowledge and was able to verify with a puts statement
  • Needed some prompting to use the console

In app/assets/javascripts/expandalbe_sections.js the candidate should find and fix the source error, which is a typo: even => event. 2: Explores the file and finds the error. Fixes the error, reloads the page and confirms the bug is fixed.

  • Candidate was able to find the error, fix it, confirm it works, and push the fix

Candidate questions:

  • What do you like about working at GH?

Tally: 12 or a 4 in Lever

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment