Cracking the Coding & PM Interview (Jan 2014)
Upcoming SlideShare
Loading in...5
×
 

Cracking the Coding & PM Interview (Jan 2014)

on

  • 265 views

CS interviews are a different breed from other interviews and, as such, require specialized skills and techniques. This talk will teach you how to prepare for coding and PM interviews, what top ...

CS interviews are a different breed from other interviews and, as such, require specialized skills and techniques. This talk will teach you how to prepare for coding and PM interviews, what top companies like Google, Amazon, and Microsoft really look for, and how to tackle the toughest programming and algorithm problems. This is not a fluffy be-your-best talk; it is deeply technical and will discuss specific algorithm and data structure topics.

Statistics

Views

Total Views
265
Views on SlideShare
265
Embed Views
0

Actions

Likes
1
Downloads
19
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment
  • Hashtables – super important!!!
  • Bit manipulation – super important!Recursion: how does recursion impact space and time?Practice converting from iterative into recursion

Cracking the Coding & PM Interview (Jan 2014) Cracking the Coding & PM Interview (Jan 2014) Presentation Transcript

  • Cracking the Coding (& PM) Interview Advice and Strategies for Software Engineering and Product Management Interviews Gayle Laakmann McDowell Founder / CEO, CareerCup.com Author of Cracking the Coding Interview, Cracking the PM Interview, & The Google Resume McDowell | CareerCup.com July 2013
  • Technical Skills Behavioral Applying My Background • Software Engineer @ Google, Microsoft & Apple – 3 Years on Google Hiring Committee – Interviewed 150+ candidates • Founder of CareerCup.com • Author – Cracking the Coding Interview – The Google Resume – Cracking the PM Interview [Product Management] Process • Interview coach for acquisitions & acquihires McDowell | CareerCup.com
  • Technical Skills Process Applying Behavioral everyone programmer s McDowell | CareerCup.com
  • Technical Skills Most Common CS Jobs Big Company Behavioral PM Dev SDET Startup Research Start Your Own Dev Research DO ALL THE THINGS Senior & Up Process Applying Junior Sophomore Freshman McDowell | CareerCup.com
  • Technical Skills Behavioral Product Manager (“PM”) == “Associate Product Manager” (Google, Yahoo, Facebook, etc.) == “Program Manager” (Microsoft) Process Applying What is a Product Manager? McDowell | CareerCup.com
  • Technical Skills Behavioral • Manage the PRODUCT, not the PEOPLE • “Build a great product for the users” – Who are the users? – What are the features? – When will we launch? – How do we launch? – etc Process Applying What is a Product Manager? McDowell | CareerCup.com
  • Technical Skills Behavioral Programmer == Software Engineer == Software Developer (Dev) == Software Design Engineer (SDE) (Microsoft) Process Applying What is a Programmer? McDowell | CareerCup.com
  • Technical Skills Behavioral • Write code (duh) • Architect systems • Plus sometimes: – Write specs – Talk to users – Figure out feature set – Etc Process Applying What is a Programmer? McDowell | CareerCup.com
  • Technical Skills Behavioral Applying Process What is an SDET? Software Test Engineer (SET) (Google) == Software Design Engineer in Test (SDET) (Microsoft) != Quality Assurance (QA) McDowell | CareerCup.com
  • • Figure out what needs to be tested and how • Write code to automate testing Technical Skills Process Applying Behavioral What is an SDET? McDowell | CareerCup.com
  • Technical Skills TODAY – Experience – Resumes – Interviews – Offers Process Applying Behavioral • Software Developer + PM McDowell | CareerCup.com
  • • 5 - 10 min – Qs about resume • 40 min – technical Qs – Coding and algorithms • 5 – 10 min – let you ask Qs, general wrap up, etc Technical Skills Process Applying Behavioral What to Expect McDowell | CareerCup.com
  • Technical Skills Big Company Evaluation (Devs) Coding Skills Intelligence Process Applying Behavioral Experience Personality McDowell | CareerCup.com Testing aptitude, not knowledge
  • Technical Skills Behavioral Applying Process Start-Ups • Coding + Intelligence • “Hit the ground running” – Do you know “their” technologies? • Entrepreneurial – Have you started things? – How much direction do you need? but… • Personality it varies! – Will you fit with the team? McDowell | CareerCup.com
  • • • • • • Communication Skills User-Focused Thinking Passion for Technology Analytical Skills Technical Skills (position dependent) Process Applying Behavioral Technical Skills PM Roles McDowell | CareerCup.com
  • Technical Skills Behavioral Applying Process How You Are Judged How did you do RELATIVE to other candidates on the SAME question? It’s not about how quickly you solved the problem… … it’s about how quickly you solved it relative to other candidates. McDowell | CareerCup.com
  • Resumes & Application Process McDowell | CareerCup.com
  • Technical Skills How to Get an Interview – Education – Work Experience – Projects – Github / Online Profile • Make a kick-ass resume Process Applying Behavioral • Your “Pedigree” McDowell | CareerCup.com
  • Technical Skills PROJECTS??? Process Applying Behavioral Did I mention… McDowell | CareerCup.com
  • Technical Skills How We Review Resumes 3. Applying Behavioral 1. 2. Reject 4. Process Pull resume out of giant stack Spot-check: company names, positions, projects, schools. Skim bullets to see if you’ve written real code. Interview Go to next resume & whine about how many more you have left. McDowell | CareerCup.com “Glanced at,” not read. 15 – 30 seconds
  • How CS Resume Should Look One Page Only! Unless > 10 years exp. A Real Resume Format with organized columns Short (1 – 2 line bullets) Focus on Accomplishments not responsibilities GPA if at least 3.0 max (in-major, overall) 3 – 4 Projects Courses & independent Finished or unfinished List of Technical Skills Short! Cut the “fluff.” Observe: No Objective! Objectives / summaries are almost always useless.
  • Technical Skills Talking to Recruiters – What you’ve done (mobile app? Show it!) – What you’re excited about • Have a “pitch” ready • Weird is okay – (arrogant is not) Process Applying Behavioral • Show: McDowell | CareerCup.com
  • Soft Questions McDowell | CareerCup.com
  • Technical Skills Behavioral • Answer the question. • Deliver a good answer. • Communicate well. – Nugget First – S.A.R.: Situation, Action, Result Process Applying Goals of Your Answer McDowell | CareerCup.com
  • Technical Skills Preparing for Behavioral Qs • Create Preparation Grid for Projects Behavioral OS Project Amazon Intern. Enjoyed Hated Applying Most Challenging Hardest Bug Process + Behavioral Grid [for PM & less tech. roles] McDowell | CareerCup.com
  • Technical Skills Structure 1: Nugget First Behavioral • Lead with your “thesis” / nugget – Grabs the listener’s attention – Gives them context for where you’re going. A: I’m most proud of the way I re-architected the … Process Applying Q: What accomplishment are you most proud of? McDowell | CareerCup.com
  • Technical Skills Structure 2: S.A.R. What was the issue? A ction What did you do about it? R esult What was the impact? Process Applying Behavioral S ituation McDowell | CareerCup.com
  • Technical Skills Good Questions for Interviewer Behavioral • Qs you want to get answered – How decisions get made – Interaction betw devs, PMs, testers • Qs that show interest / passion • Qs that show knowledge / aptitude – How did you solve problem with ___? Don’t worry too much about this stuff Process Applying – What’s the architecture like? McDowell | CareerCup.com
  • Technical Skills Interview Prep McDowell | CareerCup.com
  • Technical Skills How to study • Study the basics Behavioral • Practice solving questions Applying – Complex algorithms generally unnecessary. • Push yourself! • Write code on paper Process – Don’t memorize! – See: CtCI & CareerCup.com McDowell | CareerCup.com
  • Technical Skills Behavioral Data Structures • How to implement • When to use (pros / cons) Queues Trees Tries Graphs Vectors Applying Stacks Heaps Hashtables Process Linked Lists McDowell | CareerCup.com
  • Technical Skills Behavioral • Implementation • Space vs. Time Complexity Quick Sort Merge Sort Tree Insert / Find Binary Search Breadth-First Search Depth-First Search Process Applying Algorithms McDowell | CareerCup.com
  • Technical Skills Concepts Behavioral • Not just a concept – know how to code! Big-O Time / Space Memory Management Recursion Probability + Combinatorics Bit Manipulation Process Applying Threading McDowell | CareerCup.com
  • Technical Skills Behavioral • Necessary for “elite” tech companies – Not necessarily otherwise (check interview questions) • MIT Open Courseware – Freshman / sophomore level DS & Algo courses • Books – CLRS (Algorithms) • Online tutorials • Practice implementing and using Process Applying How to Learn CS Fundamentals? McDowell | CareerCup.com
  • Technical Skills Mastering the Interview McDowell | CareerCup.com
  • Technical Skills Behavioral 1. Product Design Questions 2. Estimation Questions 3. Software Engineering Questions – – – – Coding & Algorithms Object Oriented Design Scalability Factual / Trivia / Language-Based Process Applying Types of “Serious” Questions McDowell | CareerCup.com
  • Technical Skills Behavioral Applying Process Product Design Questions How would you design an calculator for the blind? Design an elevator for a building. Pick a Google product. How would you improve it?
  • Technical Skills Behavioral Applying Process Product Design Questions: Why? • • • • Communication & Structured Thinking Ability to understand the user Creativity Business instincts / skills
  • Technical Skills Behavioral Applying Process Product Design Qs: Approach 1. 2. 3. 4. Ask questions to resolve ambiguity Understand the user Structure the problem Solve piece by piece
  • Technical Skills Behavioral Applying Process Product Design Qs: Example How would you design a calculator for the blind? Step 1: Ask Questions • Adults? Children? Professionals? • Where are they using it? – School, work, etc.
  • Technical Skills Behavioral Applying Process Product Design Qs: Example How would you design a calculator for the blind? Step 2: Understand the User • What’s important to a blind child? – Keeping up with the rest of the class – Not feeling “different” – Efficient input / output • What about teachers, parents, classmates, etc.?
  • Technical Skills Behavioral Product Design Qs: Example How would you design a calculator for the blind? Step 3: Structure • Find a structure – Otherwise, you’re just blabbering Process Applying • One approach: 1. 2. 3. 4. Make list of functions necessary Discuss how to do input / output Usability for non-blind Summary
  • Technical Skills Behavioral Applying Process Product Design Qs: Example How would you design a calculator for the blind? Step 4: Solve!
  • Technical Skills Behavioral Applying Process Estimation Questions How many tennis balls can fit in an SUV? How much money does Gmail make from ads every year? How much do New Yorkers spend on electricity each year?
  • Technical Skills Estimation Qs: Why? Process Applying Behavioral • Problem Solving • Basic Quantitative Skills
  • Technical Skills Estimation Qs: How to Approach 1. Ask questions to resolve ambiguity Applying Behavioral – Don’t make assumptions (yet) 2. Outline / Structure Your Approach 3. Break down the components – Assume numbers when necessary – State assumptions explicitly – Round numbers to make your math easier 4. Sanity Check Process – Do your numbers make sense?
  • Technical Skills Behavioral Applying Process Estimation Qs: Example How much money does Gmail make from ads every year? Step 1: Ambiguous Information • Profit or revenue? • Past year? Or average over history? • Gmail only? Or include Google Apps?
  • Technical Skills Estimation Qs: Example How much money does Gmail make from ads every year? Process Applying Behavioral Step 2: Outline Your Approach (# of users) x (# clicks / year) x ( $ / click )
  • Technical Skills Estimation Qs: Example How much money does Gmail make from ads every year? Process Applying Behavioral Step 3: Break down components Estimate # of Gmail users in the US 1. Assume 300 million people in the US. – – Exclude 0 - 12 years old and 65 - 75 years old  ~ 200 million 2. Assume 80% of people use email 3. 80% of those have non-work account … and so on …
  • Technical Skills Behavioral Applying Process Estimation Qs: Example How much money does Gmail make from ads every year? Step 4: Validate Numbers • Could revenue be $5 billion? • No, because… – Google’s annual revenue is ~$40 billion – $16 / US citizen (not just Gmail users)
  • • • • • Knowledge Questions Coding & Algorithms Object Oriented Design Scalability Product Design Estimation Technical CS Questions McDowell | CareerCup.com
  • Technical Knowledge & Trivia Questions • Not key focus at “elite” tech companies. Estimation – If asked, tends to focus more on DS knowledge than language knowledge • If you don’t know, try to deduce the answer Product Design – How would language designer do it? etc McDowell | CareerCup.com
  • Technical Estimation Product Design Coding & Algorithm Questions 1. Understand the question – Clarify, remember key details, etc. 2. Draw an example – “Sufficiently interesting” 3. Talk out loud 4. Analyze – Does it work? What’s the big O time / space? – Do YOU understand it? If you’ve heard a 5. Code (SLOWLY) question before, 6. Test + fix (CAREFULLY) admit it. McDowell | CareerCup.com
  • Technical Estimation What does a “good coder” do? • Be methodical. Don’t try to rush. • Don’t code if you don’t understand • Reasonably Bug Free – – Thorough testing (and careful fixing) Check for error conditions Product Design • Clean coding – – – Use other functions Good use of data structures (define own if useful) Concise and readable McDowell | CareerCup.com
  • Product Design Estimation Technical Whiteboard Coding Tips Code in the FAR top left corner Write small & straight Pseudocode if you’d like Use arrows to insert new code snippets Use “good” variable names, then abbreviate • “Breadth-First” Coding • • • • • McDowell | CareerCup.com
  • Technical “Breadth-First” Coding • Divide problems into sub-components • Ex: Ransom Note – Write as one big function? – OR… modularize! Product Design Estimation – Modularize & Structure McDowell | CareerCup.com
  • Technical Product Design Estimation Ex: Ransom Note: “Depth-First” Coding McDowell | CareerCup.com
  • Technical Product Design Estimation Ex: Ransom Note: “Breadth-First” Coding McDowell | CareerCup.com
  • Technical Product Design Estimation Ex: Ransom Note: “Breadth-First” Coding McDowell | CareerCup.com
  • Technical Product Design Estimation Ex: Ransom Note: “Breadth-First” Coding McDowell | CareerCup.com
  • Technical Product Design Estimation Ex: Ransom Note: “Breadth-First” Coding McDowell | CareerCup.com
  • Technical Estimation Product Design “Breath-First” Coding • “Depth-First” Coding (One big function) – Messy – Time consuming – Poor coding style • “Breadth-First” Coding (Modularized) – – – – – “Finishes” algorithm immediately Often allows you to skip details Easier to test & fix issues Demonstrates good coding style Keeps YOU organized McDowell | CareerCup.com
  • Technical Estimation Common Mistakes • • Ignoring information given Not using examples – To design algorithms – While writing code • “Pushing through” code when confused Product Design – Incoherent thoughts -> incoherent code • • Diving into code too quickly The details: – Off-by-one, < vs <=, division (and any math) McDowell | CareerCup.com
  • Technical Types of Interview Questions Object Oriented Design System Design “Reverse a Linked List” “Design a Parking Lot” “Design a Web Crawler” Product Design Estimation Coding & Algorithms McDowell | CareerCup.com
  • Technical Types of Interview Questions Coding & Algorithms Object Oriented Design Estimation Pattern Matching Simplify & Generalize Product Design Base Case & Build Data Structure Brainstorm McDowell | CareerCup.com System Design
  • Technical Algorithm Qs: Pattern Matching Coding & Algorithms Estimation Pattern Matching Simplify & Generalize Product Design Base Case & Build Data Structure Brainstorm Object Oriented Design System Design Q: Write code to reverse the order of words in a sentence. “dogs are cute” “cute are dogs” Similar to: reverse characters in a string. “dogs are cute” “etuc era sgod” A: Reverse full string, then reverse each word. McDowell | CareerCup.com
  • Technical Algorithm Qs: Simplify & Generalize Coding & Algorithms Estimation Pattern Matching Simplify & Generalize Product Design Base Case & Build Data Structure Brainstorm Object Oriented Design System Design Q: Design algorithm to figure out if you can build a ransom note (array of strings) from a magazine (array of strings). Simplify: what if we used characters instead of strings?  Build array of character frequencies. Generalize: how we can extend answer to words? A: Build hashtable from word to frequency. McDowell | CareerCup.com
  • Technical Algorithm Qs: Base Case & Build Coding & Algorithms Estimation Pattern Matching Simplify & Generalize Product Design Base Case & Build Data Structure Brainstorm Object Oriented Design System Design Q: Design algorithm to print subsets of set. {a, b, c}  {}, {a}, {b}, {c}, {a, b}, {a, c}, {b, c}, {a, b, c} S({}) S({a}) S({a, b}) S({a, b, c})  {}  {}, {a}  {}, {a}, {b}, {a, b} ? A: Build S(n) by cloning S(n-1) and adding n to the cloned sets. McDowell | CareerCup.com
  • Technical Algorithm Qs: Data Structure Brainstorm Coding & Algorithms Estimation Pattern Matching Simplify & Generalize Product Design Base Case & Build Data Structure Brainstorm Object Oriented Design System Design Q: There are 10^10 possible phone #s. Explain how you could efficiently implement assignSpecificNum(num) and assignAnyAvailableNum(). Array (sorted)? Too slow to remove num. Linked list? Too slow to find specific num. Hash table? Can’t iterate through free nums. Tree? Ah-ha! A: Store free #s in BST. Remove when taken. McDowell | CareerCup.com
  • Technical How To Solve Algorithm Questions Coding & Algorithms Estimation Pattern Matching Simplify & Generalize Product Design Base Case & Build Data Structure Brainstorm Object Oriented Design System Design Compare to similar problems. Solve first for a simplified / tweaked problem. Solve for n = 1, and build solution for n = 2. Try to apply data structure to solve problem. McDowell | CareerCup.com
  • Technical Object Oriented Design Estimation Coding & Algorithms Object Oriented Design System Design Handle Ambiguity What about the question is ambiguous? Design the Core Objects What are the main objects in the system? Product Design Analyze Relationships How are the objects related to each other? Investigate Actions What are the main operations? McDowell | CareerCup.com
  • Technical Object Oriented Design Product Design Estimation Coding & Algorithms Object Oriented Design System Design Handle Ambiguity Is it a single restaurant, or part of a chain? How would you design the data structures and objects for a restaurant? Design the Core Objects Guest, Party, Table, Server, Host, … Analyze Relationships Server and Host are both Employees… Investigate Actions A Party is seated at a Table by a Host… McDowell | CareerCup.com
  • Technical System Design Estimation Coding & Algorithms Object Oriented Design System Design Handle Ambiguity What about the question is ambiguous? Make Believe Pretend there wasn’t so much data & solve Product Design Get Real Go back to the real problem. What breaks? Solve Problems Solve the issues you just found. McDowell | CareerCup.com
  • Technical System Design Product Design Estimation Coding & Algorithms Object Oriented Design System Design Handle Ambiguity Do the words need to be in a specific order? Given millions of documents, find all documents which contain a list of words. Make Believe Assume everything can fit on one machine. Get Real Must split up data across machines. Solve Problems Divide hash table by file or by keyword? McDowell | CareerCup.com
  • Technical Whew! All Done! Coding & Algorithms Object Oriented Design System Design Estimation Pattern Matching Simplify & Generalize <Gulp> This is a lot of stuff. Do I need to get everything right? Product Design Base Case & Build Data Structure Brainstorm McDowell | CareerCup.com
  • Technical Skills Behavioral Applying Process Evaluation is RELATIVE, not absolute. It’s not about how quickly you solved the problem… <Gulp> This is a lot of stuff. Do I need to get everything right? </Gulp> … it’s about how quickly you solved it relative to other candidates. McDowell | CareerCup.com
  • Behavioral Technical Skills Everyone makes mistakes. Everyone! Process Applying So RELAX! Interviews are supposed to be hard! McDowell | CareerCup.com
  • Technical Skills After Your Interview • Follow-up with your recruiter Applying Behavioral – No response != rejection • You have no idea how well/poorly you did. – Seriously. I know you think you do. But you don’t. • Lots of randomness. Process – So if you fail, get up and try again. McDowell | CareerCup.com
  • Process Applying Behavioral Technical Skills Negotiation McDowell | CareerCup.com
  • Technical Skills Behavioral Applying But I hate negotiating! • Welcome to the club! • You ARE in demand. • Your offer will not be revoked. Is this conversation SO terrible that you’re willing to give up $1000+**? Process ** and likely more McDowell | CareerCup.com
  • Technical Skills Negotiation Process Applying Behavioral • Most->least negotiable (generally) 1. 2. 3. 4. Signing bonus/relocation Stock Salary Other benefits • Easier if you have another offer • Counter-offer • What matters to you? McDowell | CareerCup.com
  • Technical Skills Behavioral Applying Closing Advice • • • • • Do projects Study for your interviews Chase interviews … but don’t chase money If possible, go to an “elite” tech company – (But don’t stay too long if that’s not what you want!) • Check-in on your career. Process – Is this what you want to do with your life? McDowell | CareerCup.com
  • CareerCup.com • Interview Videos • Resume Review • Mock Interviews Behavioral Technical Skills Other Resources Process Applying Or, follow me online at… • twitter.com/gayle • facebook.com/gayle • technologywoman.com • gayle@careercup.com • quora.com McDowell | CareerCup.com