CRACKING THE CODING INTERVIEW Nitish Upreti. Nitish

Slides:



Advertisements
Similar presentations
David Luebke 1 6/7/2014 CS 332: Algorithms Skip Lists Introduction to Hashing.
Advertisements

David Luebke 1 6/7/2014 ITCS 6114 Skip Lists Hashing.
CS252: Systems Programming Ninghui Li Program Interview Questions.
Interviewing. The Basics Show up on time. Look professional. – Better than the average employee. Be awake. Plan ahead to make sure you know where you.
Advanced Data Structures
CompSci Searching & Sorting. CompSci Searching & Sorting The Plan  Searching  Sorting  Java Context.
1 CSC 421: Algorithm Design & Analysis Spring 2013 See online syllabus: (also on BlueLine2) Course.
CS 307 Fundamentals of Computer Science 1 Abstract Data Types many slides taken from Mike Scott, UT Austin.
DAST, Spring © L. Joskowicz 1 Data Structures – LECTURE 1 Introduction Motivation: algorithms and abstract data types Easy problems, hard problems.
1 Advanced Data Structures. 2 Topics Data structures (old) stack, list, array, BST (new) Trees, heaps, union-find, hash tables, spatial, string Algorithm.
Data Structures & Algorithms What The Course Is About s Data structures is concerned with the representation and manipulation of data. s All programs.
CS 206 Introduction to Computer Science II 10 / 14 / 2009 Instructor: Michael Eckmann.
Tirgul 8 Universal Hashing Remarks on Programming Exercise 1 Solution to question 2 in theoretical homework 2.
CS503: Tenth Lecture, Fall 2008 Review Michael Barnathan.
Computer Science 2 Data Structures and Algorithms V section 2 Intro to “big o” Lists Professor: Evan Korth New York University 1.
DAST, Spring © L. Joskowicz 1 Data Structures – LECTURE 1 Introduction Motivation: algorithms and abstract data types Easy problems, hard problems.
A Primer on Jobs in Industry Nitin Jindal Department of Computer Science University of Illinois at Chicago.
Computer Science 2 Data Structures and Algorithms V Intro to “big o” Lists Professor: Evan Korth New York University 1.
Computer Science 102 Data Structures and Algorithms V Fall 2009 Lecture 1: administrative details Professor: Evan Korth New York University 1.
Instructor: Dr. Sahar Shabanah Fall Lectures ST, 9:30 pm-11:00 pm Text book: M. T. Goodrich and R. Tamassia, “Data Structures and Algorithms in.
1 What NOT to do I get sooooo Frustrated! Marking the SAME wrong answer hundreds of times! I will give a list of mistakes which I particularly hate marking.
Teaching Teaching Discrete Mathematics and Algorithms & Data Structures Online G.MirkowskaPJIIT.
Take the Hassle Out of Hiring Peter Dods. Resume No Job Applications Resume – 1 st initiative test How does resume look Is the resume geared towards working.
Data Structures Lecture 1: Introduction Azhar Maqsood NUST Institute of Information Technology (NIIT)
Lecture No.01 Data Structures Dr. Sohail Aslam
Chapter 3 List Stacks and Queues. Data Structures Data structure is a representation of data and the operations allowed on that data. Data structure is.
Data Structures and Abstract Data Types "Get your data structures correct first, and the rest of the program will write itself." - David Jones.
1 CS 233 Data Structures and Algorithms 황승원 Fall 2010 CSE, POSTECH.
Sorting HKOI Training Team (Advanced)
Lecture 10: Class Review Dr John Levine Algorithms and Complexity March 13th 2006.
Search - on the Web and Locally Related directly to Web Search Engines: Part 1 and Part 2. IEEE Computer. June & August 2006.
Algorithm Fundamentals Shane Carr CSE 232, Fall 2015.
Computer Science 102 Data Structures and Algorithms CSCI-UA.0102 Fall 2012 Lecture 1: administrative details Professor: Evan Korth New York University.
Major objective of this course is: Design and analysis of modern algorithms Different variants Accuracy Efficiency Comparing efficiencies Motivation thinking.
By: Lokman Chan Recursive Algorithm Recursion Definition: A function that is define in terms of itself. Goal: Reduce the solution to.
Can’t provide fast insertion/removal and fast lookup at the same time Vectors, Linked Lists, Stack, Queues, Deques 4 Data Structures - CSCI 102 Copyright.
CSE373: Data Structures & Algorithms Lecture 22: The P vs. NP question, NP-Completeness Lauren Milne Summer 2015.
1 1.Log in to the computer in front of you –Temp account: 231class / 2.Update your in Cascadia's system –If I need to you I'll use.
Elementary Data Organization. Outline  Data, Entity and Information  Primitive data types  Non primitive data Types  Data structure  Definition 
Sell yourself in an interview
Hashtables. An Abstract data type that supports the following operations: –Insert –Find –Remove Search trees can be used for the same operations but require.
Week 10 - Friday.  What did we talk about last time?  Graph representations  Adjacency matrix  Adjacency lists  Depth first search.
Independent Reading Day #1 (Sad, but true.). Let’s do an experiment: Figure out a starting page number for today’s reading – It might not be page one.
BIT 143: Programming – Data Structures It is assumed that you will also be present for the slideshow for the first day of class. Between that slideshow.
Fall 2015, Kevin Quinn CSE373: Data Structures & Algorithms Lecture 25: Problem Solving CSE373: Data Structures and algorithms1.
Course Info Instructor U.T. Nguyen Office: CSEB Office hours: Tuesday, 14:30-15:30 Thursday, 12:00-12:45 By.
Data Structures and Algorithms in Java AlaaEddin 2012.
Team assignments in CS 322 “Data Structures & Algorithms II” Jey Veerasamy CIS Adjunct Faculty Baker College Online.
CSC490 – Effect of Internship Experience on Technical Knowledge of Graduating CS Students By Tong Zou.
Principles of Imperative Computation Lecture 1 January 15 th, 2012.
Elevator Speeches AVID 4.
BITS Pilani Pilani Campus Data Structure and Algorithms Design Dr. Maheswari Karthikeyan Lecture1.
CSC 143T 1 CSC 143 Highlights of Tables and Hashing [Chapter 11 p (Tables)] [Chapter 12 p (Hashing)]
Introduction to Algorithm Complexity Bit Sum Problem.
Algorithm homework help For More Detail help.aspx - Phone:-
CSC 421: Algorithm Design & Analysis
COMP9024: Data Structures and Algorithms
CSC 421: Algorithm Design & Analysis
Hashing Exercises.
Computer Science 102 Data Structures CSCI-UA
CSC 421: Algorithm Design & Analysis
structures and their relationships." - Linus Torvalds
Randomized Algorithms CS648
Objective of This Course
Data Structures: Introductory lecture
COSC 320 Advanced Data Structures and Algorithm Analysis
COP3530- Data Structures Introduction
structures and their relationships." - Linus Torvalds
Algorithm Course Algorithms Lecture 3 Sorting Algorithm-1
Presentation transcript:

CRACKING THE CODING INTERVIEW Nitish Upreti

Nitish

Feedback Please ! ( I am a Data Junkie… )

Why this Talk? Why should you care ?

For the love of Computer Science …

Building Amazing Products

Working with the best of People…

Have an Impact !

Head start in Building your career …

Money & Free Food ?

Start Your own Company ?

Working for the Top Technology Companies. (Computer Science-Engineering majors are most pampered and well paid…)

Easy : Just clear the coding interview ?

Or Not ?

Some of us are scared ! How does the interview work? What do they judge me on? Do’s / Don’ts

Are these interviews fair? Can you judge someone in few hours or a day?

Think of Interviews as acing SATs / GREs … ( Whether they are any good is debatable!)

GAME PLAN : 1. Study all my subjects well. 2. Finish all Assignments/Projects. 3. Get an awesome GPA.

There is more to it …

Would you practice for a Sprint by running marathons each day?

Preparations Matter! “Sweat now so you don't bleed later.” Take Away….

Lets get cracking!

Before the Interview…

How to get interviews at the first place? Career fairs. Referrals from friends and seniors. (Almost guarantees an interview) Be active on LinkedIn. Visit Hackathons. Start competing on HackerRank / TopCoder. cto_first_name /

Quick Preliminaries Perfect your resume (No spelling mistakes / grammar errors) ACM provides help! Prepare Behavioral Questions Judging You On : What you learned? Most Challenging Problems ? Most Interesting Problem ? Hardest Bug ? Enjoyed Most ? Conflict with Teammates ?

So I got the call

How does the Interview Process work ? ( At least for the Popular Ones …. )

Interview Process Starts with an Conversation. Scheduling day/time for Phone or Campus screening Internships : Usually 2 telephonic rounds. Full time : 5-7 interviews PSU Microsoft experience is an exception when it comes to interviews. (Why?) You are notified in a couple of weeks. Details are in the Book!

How should I prepare ?

White Board Coding…. (Without the cozy compiler : Marathon and Sprint metaphor again!)

What should I prepare?

Almost Comprehensive List … Elementary DS : – Arrays, Stacks & Queues – Linked Lists – Trees ( Binary Trees, Binary Search Trees) – Hash Tables Asymptotic Analysis Sorting with their Runtimes. Recursion ! String Problems Good to know : TRIE and Priority Queue ( BinaryHeap)

Advanced Divide and Conquer Algorithms. Greedy Algorithms Dynamic Programming Graph Algorithms Some Design Problems

During the Interview …

Key things to keep in mind All questions are language independent. Start Talking ( Interviewers nudge you towards the right direction ) Think before you start / Don’t rush. Propose a variety of solutions idea before settling on coding a particular idea. Sound Enthusiastic ! Ask questions in the end : How do you work? What do you work on?

Make Or Break it ! Think about Corner cases. Test your code once your done. Be Space / Time Efficient. ( Distinguishes a Good Vs Bad Interview)

Lets dissect a real interview question !

Given a set of integers, is there a subset of size k whose sum is zero? Array = { 3, 9, 1, 6, 0, 2 } Sum = 8

I am STUMPED !

Let us start talking ….

Brute Force Anyone ? Find all the possible sums and if the given sum is one of them, we have a solution! Brute Force could be a good start. Don’t code it yet !

Runtime Analysis ? O ( N 2 )

Can we do better? At Google’s scale there will be Billion Numbers !

Sorting + Binary Search ? O (N log N) + O (log N)

Can we do Even Better?

How about a Hash Table Solution? First Passes : Create a Map (HashMap) Array = { 3, 9, 1, 6, 0, 2 } Hash = { (3,T) (9,T) (1,T) (6,T) (0,T)(2,T) } Scan through the keys & look for remainder.

Corner Case : Duplicate Elements ! Array = { 3, 9, 1, 6, 0, 4 } Hash = { (3,T) (9,T) (1,T) (6,T) (0,T)(4,T) } Solution : Store Count !

Complexity ? Time : O ( N ) Space : O ( N )

MUST READ Books …

Before I Finish …

GSoC 2014 Is On!

Feedback / Questions ?