{"product_id":"programming-interviews-exposed-9781119418474","title":"Programming Interviews Exposed","description":"\u003cb\u003eBook Synopsis\u003c\/b\u003e\u003cbr\u003e\u003cp\u003e\u003cb\u003eAce technical interviews with smart preparation\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003e\u003ci\u003eProgramming Interviews Exposed\u003c\/i\u003e is the programmer's ideal first choice for technical interview preparation. Updated to reflect changing techniques and trends, this new fourth edition provides insider guidance on the unique interview process that today''s programmers face. Online coding contests are being used to screen candidate pools of thousands, take-home projects have become commonplace, and employers are even evaluating a candidate''s public code repositories at GitHuband with competition becoming increasingly fierce, programmers need to shape themselves into the ideal candidate well in advance of the interview. This book doesn''t just give you a collection of questions and answers, it walks you through the process of coming up with the solution so you learn the skills and techniques to shine on whatever problems you're given.\u003c\/p\u003e \u003cp\u003eThis edition combines a thoroughly revised basis in classic questions involvin\u003cbr\u003e\u003cbr\u003e\u003cb\u003eTable of Contents\u003c\/b\u003e\u003cbr\u003e\u003c\/p\u003e\u003cp\u003ePreface xxv\u003c\/p\u003e \u003cp\u003eIntroduction xxix\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 1: Before the Search 1\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eKnow Yourself 1\u003c\/p\u003e \u003cp\u003eKnow the Market 3\u003c\/p\u003e \u003cp\u003eBasic Market Information 3\u003c\/p\u003e \u003cp\u003eWhat About Outsourcing? 4\u003c\/p\u003e \u003cp\u003eDevelop Marketable Skills 5\u003c\/p\u003e \u003cp\u003eGet Things Done 6\u003c\/p\u003e \u003cp\u003eManage Your Online Profile 7\u003c\/p\u003e \u003cp\u003eSummary 8\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 2: the Job Application Process 9\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eFinding and Contacting Companies 9\u003c\/p\u003e \u003cp\u003eFinding Companies 9\u003c\/p\u003e \u003cp\u003eGetting Referrals 10\u003c\/p\u003e \u003cp\u003eWorking with Headhunters 10\u003c\/p\u003e \u003cp\u003eContacting the Company Directly 11\u003c\/p\u003e \u003cp\u003eJob Fairs 12\u003c\/p\u003e \u003cp\u003eTechnology-Driven Sites 12\u003c\/p\u003e \u003cp\u003eThe Interview Process 12\u003c\/p\u003e \u003cp\u003eScreening Interviews 12\u003c\/p\u003e \u003cp\u003eOn-Site Interviews 13\u003c\/p\u003e \u003cp\u003eDress 14\u003c\/p\u003e \u003cp\u003eA Recruiter’s Role 14\u003c\/p\u003e \u003cp\u003eOffers and Negotiation 15\u003c\/p\u003e \u003cp\u003eDealing with Recruiter Pressures 15\u003c\/p\u003e \u003cp\u003eNegotiating Your Salary 15\u003c\/p\u003e \u003cp\u003eAccepting and Rejecting Offers 17\u003c\/p\u003e \u003cp\u003eSummary 17\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 3: the Phone Screen 19\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eUnderstanding Phone Screens 19\u003c\/p\u003e \u003cp\u003ePhone Screens by Software Engineers 19\u003c\/p\u003e \u003cp\u003ePhone Screens by Nontechnical People 20\u003c\/p\u003e \u003cp\u003eHow to Take a Phone Screen 21\u003c\/p\u003e \u003cp\u003ePhone Screen Problems 22\u003c\/p\u003e \u003cp\u003eMemory Allocation in c 22\u003c\/p\u003e \u003cp\u003eRecursion Trade-Offs 22\u003c\/p\u003e \u003cp\u003eMobile Programming 23\u003c\/p\u003e \u003cp\u003eFizzBuzz 23\u003c\/p\u003e \u003cp\u003eReversing a String 24\u003c\/p\u003e \u003cp\u003eRemoving Duplicates 25\u003c\/p\u003e \u003cp\u003eNested Parentheses 26\u003c\/p\u003e \u003cp\u003eSummary 27\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 4: Approaches to Programming Problems 29\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eThe Process 29\u003c\/p\u003e \u003cp\u003eThe Scenario 29\u003c\/p\u003e \u003cp\u003eThe Problems 30\u003c\/p\u003e \u003cp\u003eWhich Languages to Use 30\u003c\/p\u003e \u003cp\u003eInteractivity Is Key 31\u003c\/p\u003e \u003cp\u003eSolving the Problems 32\u003c\/p\u003e \u003cp\u003eThe Basic Steps 32\u003c\/p\u003e \u003cp\u003eWhen You Get Stuck 34\u003c\/p\u003e \u003cp\u003eAnalyzing Your Solution 34\u003c\/p\u003e \u003cp\u003eBig-O O Analysis 35\u003c\/p\u003e \u003cp\u003eHow Big-O O Analysis Works 36\u003c\/p\u003e \u003cp\u003eBest, Average, and Worst Cases 37\u003c\/p\u003e \u003cp\u003eOptimizations and Big-O O Analysis 37\u003c\/p\u003e \u003cp\u003eHow to Do Big-O O Analysis 38\u003c\/p\u003e \u003cp\u003eWhich Algorithm Is Better? 38\u003c\/p\u003e \u003cp\u003eMemory Footprint Analysis 39\u003c\/p\u003e \u003cp\u003eSummary 40\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 5: Linked Lists 41\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eWhy Linked Lists? 41\u003c\/p\u003e \u003cp\u003eKinds of Linked Lists 42\u003c\/p\u003e \u003cp\u003eSingly Linked Lists 42\u003c\/p\u003e \u003cp\u003eDoubly Linked Lists 44\u003c\/p\u003e \u003cp\u003eCircular Linked Lists 44\u003c\/p\u003e \u003cp\u003eBasic Linked List Operations 44\u003c\/p\u003e \u003cp\u003eTracking the Head Element 44\u003c\/p\u003e \u003cp\u003eTraversing a List 46\u003c\/p\u003e \u003cp\u003eInserting and Deleting Elements 46\u003c\/p\u003e \u003cp\u003eLinked List Problems 48\u003c\/p\u003e \u003cp\u003eStack Implementation 48\u003c\/p\u003e \u003cp\u003eMaintain Linked List Tail Pointer 54\u003c\/p\u003e \u003cp\u003eBugs in removeHead 60\u003c\/p\u003e \u003cp\u003eMth-to-Last Element of a Linked List 62\u003c\/p\u003e \u003cp\u003eList Flattening 65\u003c\/p\u003e \u003cp\u003eList Unflattening 68\u003c\/p\u003e \u003cp\u003eNull or Cycle 70\u003c\/p\u003e \u003cp\u003eSummary 73\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 6: Trees and Graphs 75\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eTrees 75\u003c\/p\u003e \u003cp\u003eBinary Trees 77\u003c\/p\u003e \u003cp\u003eBinary Search Trees 78\u003c\/p\u003e \u003cp\u003eHeaps 80\u003c\/p\u003e \u003cp\u003eCommon Searches 80\u003c\/p\u003e \u003cp\u003eBreadth-First Search 80\u003c\/p\u003e \u003cp\u003eDepth-First Search 81\u003c\/p\u003e \u003cp\u003eTraversals 81\u003c\/p\u003e \u003cp\u003eGraphs 82\u003c\/p\u003e \u003cp\u003eTree and Graph Problems 83\u003c\/p\u003e \u003cp\u003eHeight of a Tree 83\u003c\/p\u003e \u003cp\u003ePreorder Traversal 84\u003c\/p\u003e \u003cp\u003ePreorder Traversal, No Recursion 85\u003c\/p\u003e \u003cp\u003eLowest Common Ancestor 87\u003c\/p\u003e \u003cp\u003eBinary Tree to Heap 88\u003c\/p\u003e \u003cp\u003eUnbalanced Binary Search Tree 91\u003c\/p\u003e \u003cp\u003eSix Degrees of Kevin Bacon 93\u003c\/p\u003e \u003cp\u003eSummary 97\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 7: Arrays and Strings 99\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eArrays 99\u003c\/p\u003e \u003cp\u003eC and C++ 100\u003c\/p\u003e \u003cp\u003eJava 101\u003c\/p\u003e \u003cp\u003eC# 102\u003c\/p\u003e \u003cp\u003eJavaScript 102\u003c\/p\u003e \u003cp\u003eStrings 102\u003c\/p\u003e \u003cp\u003eC 103\u003c\/p\u003e \u003cp\u003eC++ 104\u003c\/p\u003e \u003cp\u003eJava 104\u003c\/p\u003e \u003cp\u003eC# 105\u003c\/p\u003e \u003cp\u003eJavaScript 105\u003c\/p\u003e \u003cp\u003eArray and String Problems 105\u003c\/p\u003e \u003cp\u003eFind the First Nonrepeated Character 106\u003c\/p\u003e \u003cp\u003eRemove Specified Characters 109\u003c\/p\u003e \u003cp\u003eReverse Words 112\u003c\/p\u003e \u003cp\u003eInteger\/String Conversions 116\u003c\/p\u003e \u003cp\u003eFrom String to Integer 116\u003c\/p\u003e \u003cp\u003eFrom Integer to String 118\u003c\/p\u003e \u003cp\u003eUTF-8 String Validation 121\u003c\/p\u003e \u003cp\u003eSummary 124\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 8: Recursion 125\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eUnderstanding Recursion 125\u003c\/p\u003e \u003cp\u003eRecursion Problems 129\u003c\/p\u003e \u003cp\u003eBinary Search 129\u003c\/p\u003e \u003cp\u003ePermutations of a String 131\u003c\/p\u003e \u003cp\u003eCombinations of a String 134\u003c\/p\u003e \u003cp\u003eTelephone Words 137\u003c\/p\u003e \u003cp\u003eSummary 142\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 9: Sorting 143\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eSorting Algorithms 143\u003c\/p\u003e \u003cp\u003eSelection Sort 144\u003c\/p\u003e \u003cp\u003eInsertion Sort 145\u003c\/p\u003e \u003cp\u003eQuicksort 146\u003c\/p\u003e \u003cp\u003eMerge Sort 148\u003c\/p\u003e \u003cp\u003eSorting Problems 149\u003c\/p\u003e \u003cp\u003eThe Best Sorting Algorithm 150\u003c\/p\u003e \u003cp\u003eStable Selection Sort 153\u003c\/p\u003e \u003cp\u003eMulti-Key Sort 155\u003c\/p\u003e \u003cp\u003eMake a Sort Stable 156\u003c\/p\u003e \u003cp\u003eOptimized Quicksort 158\u003c\/p\u003e \u003cp\u003ePancake Sorting 161\u003c\/p\u003e \u003cp\u003eSummary 163\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 10: Concurrency 165\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eBasic Thread Concepts 165\u003c\/p\u003e \u003cp\u003eThreads 165\u003c\/p\u003e \u003cp\u003eSystem Threads versus User Threads 166\u003c\/p\u003e \u003cp\u003eMonitors and Semaphores 166\u003c\/p\u003e \u003cp\u003eDeadlocks 167\u003c\/p\u003e \u003cp\u003eA Threading Example 168\u003c\/p\u003e \u003cp\u003eConcurrency Problems 170\u003c\/p\u003e \u003cp\u003eBusy Waiting 170\u003c\/p\u003e \u003cp\u003eProducer\/Consumer 172\u003c\/p\u003e \u003cp\u003eThe Dining Philosophers 175\u003c\/p\u003e \u003cp\u003eSummary 179\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 11: Object-oriented Programming 181\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eFundamentals 181\u003c\/p\u003e \u003cp\u003eClasses and Objects 181\u003c\/p\u003e \u003cp\u003eConstruction and Destruction 182\u003c\/p\u003e \u003cp\u003eInheritance and Polymorphism 183\u003c\/p\u003e \u003cp\u003eObject-Oriented Programming Problems 184\u003c\/p\u003e \u003cp\u003eInterfaces and Abstract Classes 184\u003c\/p\u003e \u003cp\u003eVirtual Methods 186\u003c\/p\u003e \u003cp\u003eMultiple Inheritance 188\u003c\/p\u003e \u003cp\u003eResource Management 189\u003c\/p\u003e \u003cp\u003eSummary 191\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 12: Design Patterns 193\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eWhat Are Design Patterns? 193\u003c\/p\u003e \u003cp\u003eWhy Use Design Patterns? 193\u003c\/p\u003e \u003cp\u003eDesign Patterns in Interviews 194\u003c\/p\u003e \u003cp\u003eCommon Design Patterns 194\u003c\/p\u003e \u003cp\u003eSingleton 195\u003c\/p\u003e \u003cp\u003eBuilder 195\u003c\/p\u003e \u003cp\u003eIterator 197\u003c\/p\u003e \u003cp\u003eObserver 197\u003c\/p\u003e \u003cp\u003eDecorator 197\u003c\/p\u003e \u003cp\u003eDesign Pattern Problems 198\u003c\/p\u003e \u003cp\u003eSingleton Implementation 198\u003c\/p\u003e \u003cp\u003eDecorator versus Inheritance 201\u003c\/p\u003e \u003cp\u003eEfficient Observer Updates 202\u003c\/p\u003e \u003cp\u003eSummary 202\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 13: Databases 203\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eDatabase Fundamentals 203\u003c\/p\u003e \u003cp\u003eRelational Databases 203\u003c\/p\u003e \u003cp\u003eSQL 204\u003c\/p\u003e \u003cp\u003eNoSQL 208\u003c\/p\u003e \u003cp\u003eObject Databases 209\u003c\/p\u003e \u003cp\u003eHybrid Key-Value\/Column Databases 209\u003c\/p\u003e \u003cp\u003eDatabase Transactions 210\u003c\/p\u003e \u003cp\u003eDistributed Databases 211\u003c\/p\u003e \u003cp\u003eDatabase Problems 212\u003c\/p\u003e \u003cp\u003eSimple SQL 212\u003c\/p\u003e \u003cp\u003eCompany and Employee Database 212\u003c\/p\u003e \u003cp\u003eMax, No Aggregates 215\u003c\/p\u003e \u003cp\u003eThree-Valued Logic 216\u003c\/p\u003e \u003cp\u003eSchool Schemata 218\u003c\/p\u003e \u003cp\u003eSummary 222\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 14: Graphics and Bit Manipulation 223\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eGraphics 223\u003c\/p\u003e \u003cp\u003eBit Manipulation 224\u003c\/p\u003e \u003cp\u003eBinary Two’s Complement Notation 224\u003c\/p\u003e \u003cp\u003eBitwise Operators 225\u003c\/p\u003e \u003cp\u003eOptimizing with Shifts 226\u003c\/p\u003e \u003cp\u003eGraphics Problems 226\u003c\/p\u003e \u003cp\u003eEighth of a Circle 227\u003c\/p\u003e \u003cp\u003eRectangle Overlap 229\u003c\/p\u003e \u003cp\u003eBit Manipulation Problems 232\u003c\/p\u003e \u003cp\u003eBig-Endian or Little-Endian 233\u003c\/p\u003e \u003cp\u003eNumber of Ones 235\u003c\/p\u003e \u003cp\u003eSummary 237\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 15: Data Science, Random Numbers, And Statistics 239\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eProbability and Statistics 240\u003c\/p\u003e \u003cp\u003eDescriptive and Inferential Statistics 241\u003c\/p\u003e \u003cp\u003eConfidence Intervals 242\u003c\/p\u003e \u003cp\u003eStatistical Tests 242\u003c\/p\u003e \u003cp\u003eArtificial Intelligence and Machine Learning 244\u003c\/p\u003e \u003cp\u003eRandom Number Generators 245\u003c\/p\u003e \u003cp\u003eData Science, Random Number and Statistical Problems 246\u003c\/p\u003e \u003cp\u003eIrreproducible Results 247\u003c\/p\u003e \u003cp\u003eStudy More; Know Less 249\u003c\/p\u003e \u003cp\u003eRoll the Dice 251\u003c\/p\u003e \u003cp\u003eCalculate Pi 254\u003c\/p\u003e \u003cp\u003eSummary 258\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 16: Counting, Measuring, and Ordering Puzzles 259\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eTackling Brainteasers 259\u003c\/p\u003e \u003cp\u003eBeware of Assumptions 260\u003c\/p\u003e \u003cp\u003eDon’t Be Intimidated 261\u003c\/p\u003e \u003cp\u003eBeware of Simple Problems 262\u003c\/p\u003e \u003cp\u003eEstimation Problems 262\u003c\/p\u003e \u003cp\u003eBrainteaser Problems 263\u003c\/p\u003e \u003cp\u003eCount Open Lockers 263\u003c\/p\u003e \u003cp\u003eThree Switches 265\u003c\/p\u003e \u003cp\u003eBridge Crossing 266\u003c\/p\u003e \u003cp\u003eHeavy Marble 269\u003c\/p\u003e \u003cp\u003eNumber of American Gas Stations 273\u003c\/p\u003e \u003cp\u003eSummary 274\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 17: Graphical and Spatial Puzzles 275\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eDraw It First 275\u003c\/p\u003e \u003cp\u003eGraphical and Spatial Problems 276\u003c\/p\u003e \u003cp\u003eBoat and Pier 276\u003c\/p\u003e \u003cp\u003eCounting Cubes 278\u003c\/p\u003e \u003cp\u003eThe Fox and the Duck 282\u003c\/p\u003e \u003cp\u003eBurning Fuses 283\u003c\/p\u003e \u003cp\u003eEscaping the Train 286\u003c\/p\u003e \u003cp\u003eSummary 287\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 18: Knowledge-based Questions 289\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003ePreparation 289\u003c\/p\u003e \u003cp\u003eProblems 290\u003c\/p\u003e \u003cp\u003eC++ versus Java 291\u003c\/p\u003e \u003cp\u003eFriend Classes 292\u003c\/p\u003e \u003cp\u003eArgument Passing 292\u003c\/p\u003e \u003cp\u003eMacros and Inline Functions 294\u003c\/p\u003e \u003cp\u003eInheritance 295\u003c\/p\u003e \u003cp\u003eGarbage Collection 296\u003c\/p\u003e \u003cp\u003e32-Bit versus 64-Bit Applications 297\u003c\/p\u003e \u003cp\u003eNetwork Performance 298\u003c\/p\u003e \u003cp\u003eWeb Application Security 298\u003c\/p\u003e \u003cp\u003eCryptography 301\u003c\/p\u003e \u003cp\u003eHash Tables versus Binary Search Trees 301\u003c\/p\u003e \u003cp\u003eMapReduce 302\u003c\/p\u003e \u003cp\u003eSummary 302\u003c\/p\u003e \u003cp\u003e\u003cb\u003eChapter 19: Nontechnical Questions 303\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eWhy Nontechnical Questions? 303\u003c\/p\u003e \u003cp\u003eQuestions 304\u003c\/p\u003e \u003cp\u003e“What Do You Want to Do?” 304\u003c\/p\u003e \u003cp\u003e“What Is Your Favorite Programming Language?” 305\u003c\/p\u003e \u003cp\u003e“What Is Your Work Style?” 306\u003c\/p\u003e \u003cp\u003e“What Can You Tell Me About Your Experience?” 306\u003c\/p\u003e \u003cp\u003e“What Are Your Career Goals?” 306\u003c\/p\u003e \u003cp\u003e“Why Are You Looking to Change Jobs?” 306\u003c\/p\u003e \u003cp\u003e“What Salary Are You Expecting?” 307\u003c\/p\u003e \u003cp\u003e“What Is Your Salary History?” 310\u003c\/p\u003e \u003cp\u003e“Why Should We Hire You?” 310\u003c\/p\u003e \u003cp\u003e“Why Do You Want to Work for This Company?” 311\u003c\/p\u003e \u003cp\u003e“Do You Have Any Questions for Me?” 311\u003c\/p\u003e \u003cp\u003eSummary 311\u003c\/p\u003e \u003cp\u003e\u003cb\u003eAppendix: Résumés 313\u003c\/b\u003e\u003c\/p\u003e \u003cp\u003eThe Technical Résumé 313\u003c\/p\u003e \u003cp\u003eA Poor Example 313\u003c\/p\u003e \u003cp\u003eSell Yourself 317\u003c\/p\u003e \u003cp\u003eKeep It Short 317\u003c\/p\u003e \u003cp\u003eList the Right Information 318\u003c\/p\u003e \u003cp\u003eBe Clear and Concise 319\u003c\/p\u003e \u003cp\u003eRelevant Information Only 320\u003c\/p\u003e \u003cp\u003eUse Reverse Chronological Ordering 321\u003c\/p\u003e \u003cp\u003eAlways Proofread 321\u003c\/p\u003e \u003cp\u003eAn Improved Example 321\u003c\/p\u003e \u003cp\u003eManagers and Senior Developers 323\u003c\/p\u003e \u003cp\u003eTailor the Résumé to the Position 329\u003c\/p\u003e \u003cp\u003eSample Résumé 329\u003c\/p\u003e \u003cp\u003eIndex 333\u003c\/p\u003e","brand":"John Wiley \u0026 Sons Inc","offers":[{"title":"Default Title","offer_id":48866394898775,"sku":"9781119418474","price":21.25,"currency_code":"GBP","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0817\/1739\/5799\/files\/9781119418474.jpg?v=1722278447","url":"https:\/\/bookcurl.com\/products\/programming-interviews-exposed-9781119418474","provider":"Book Curl","version":"1.0","type":"link"}