/ctci

Cracking the Coding Interview and Misc

Primary LanguageRuby

Cracking The Coding Interview

I've written very little code in teh last few months and am starting a set of technical interviews. Like any good candidate it's time to do some prep work. Crackign the Codign Interview is a classic book enumerating a number of questions that frequently appear in coding interviews. It covers a number of techniques and strategies that can be extrapolated to solve the vast mojority (~80%) of coding questions. In reality, Ive never worked through this book so this is a needed refresher.

While conducting and participating in interviews i've heard from candidates, nterviewers and friends in these categories a number of concerns about this interviewing format. THe chief of which sounds something like this: "You'll never have to work liek this in teh actual job! We don't write code on whiteboards and we rarely have to do problems like these." This has some truth to it. However, in reality it's the typically kvetching of a frustrated candidate. There are roughly 50 problems that are typically asked in a technical interview. Learn the 50 problems and their techniques and insights and you can pass all the technical questions in this format. It's an established contract in technical interviewing. If you can't than you've done poor preparation! This is typically my response, but the irony is.... I don't know the 50 problems. So here we go!

I will also add problems that I've been asked during my current interview cycle here. This may be a nice way to show a hit map or discover unaddressed territory.

  • Product a function to generate all unique tetris pieces. Extend to pieces where n != 4

  • Determine whether 2 given string are rotations of each other

  • Write a chat app

  • Find the length of the maximal substring containing at most X distinct characters

  • Find the maximum contiguous sum in an array of integers

  • Write a function in javascript that can be used to simulate asynchronicity (additional materials necessary)

  • Write a function that takes in very large strings of integers and adds them. Numbers can be positive or negative. 1 digit addition is okay.

  • Balanced Parentheses while determining the number of characters in between the parens

  • Write some SQL!

  • Generate all values less then N that are the sums of 2 distinct primes

  • Write a function to determine if 2 words are anagrams of each other. The write a function to detemrine whether a word is a palindrome

  • Write an implemnetation of a set.

  • Design a large scale in-memory storage system

  • Write a function to generate all narcississtic numbers.

  • Write a function that takes in a series of heights corresponding to 2d skysscapres of width 1. Determine how much "rain" would be caputure in that 2d configuration of buildlings. Lol this is a silly description but...

  • Design a Github clone

  • Write a React component with Tabs and components or whatever