Giter Site home page Giter Site logo

juemura / nb_whiteboarding Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ggorlen/nb_whiteboarding

0.0 2.0 1.0 5.48 MB

Problems discussed at weekly whiteboarding meetups at Noisebridge

Python 71.12% Java 9.31% C 9.78% Ruby 4.59% Perl 1.50% C++ 3.69%

nb_whiteboarding's Introduction

Noisebridge Whiteboarding Workshop

This is an archive of whiteboarding problems discussed at weekly whiteboarding meetups at Noisebridge. Make a PR if you've written a solution.

Starting out

If you're new to whiteboarding, here's a miniature prerequisite roadmap to help prepare you for the experience:

  1. Learn programming fundamentals (variables, functions, loops, arrays, etc). Python is a popular language choice; however, most algorithm books use Java, C or C++, so exposure to one of those is recommended.
  2. Explore the basics of data structures and algorithms (big-O, stacks, queues, graphs, hashing, sorting, searching, etc).
  3. Grab a copy of Cracking the Coding Interview, read a few chapters and try some problems.
  4. Sign up for LeetCode and other coding challenge sites and keep solving!

Pull request guidelines

  • Please adhere to your language's typical style guidelines for indentation, whitespace and casing.
  • Focus on realistic solutions to whiteboarding problems (cap lines of code at a reasonable amount but feel free to subtract lines used to write larger helper functions that an interviewer would typically allow to be abbreviated, like a disjoint-set).
  • Add a simple test suite or driver code.

Past problems

Other Problems

  1. Merge Sort

11/07/2018

  1. Longest path in DAG
  2. BST to linked list
  3. K smallest numbers in array

11/14/2018

  1. Rotate array
  2. Detect cycle in undirected graph
  3. Roads and Libraries
  4. New Year Chaos

11/21/2018

  1. Bouquet of flowers
  2. First missing positive
  3. Median of two sorted arrays

11/28/2018

  1. Find the duplicate number
  2. N-th Fibonacci Number
  3. Shortest Supersequence
  4. Design a spreadsheet

12/05/2018

  1. Collect maximum points in a grid using two traversals (similar: Cherry Pickup)
  2. Largest time for given digits
  3. Reveal cards in increasing order
  4. Flip equivalent binary trees
  5. Design an elevator
  6. Given a sequence of points where consecutive points are connected by line segments to make a path, return the point along the path that corresponds to a given percentage along the path.

12/12/2018

  1. Longest file path
  2. Write the most efficient data structure that stores the last N records of orders to a company that supports two operations: (1) Return the record for the ith last order and (2) add a new record for a new order.
  3. Write a post-order traversal of a binary tree using iteration
  4. Concurrent sum
  5. Force order in concurrency (Similar)
  6. Select a random number from a stream with O(1) space
  7. Find missing number in an array of N-1 elements where number from 1 to N is missing. (Similar)
  8. CTCI 17.24, Max Submatrix: Given an NxN matrix of positive and negative integers, write code to find the submatrix with the largest possible sum. Variant: submatrix is not necessarily square.

12/19/2018

  1. Dependency resolution (Similar to CTCI 4.7)
  2. CTCI 2.5: Add two numbers stored in linked lists
  3. CTCI 2.3: Delete a node in the middle of a singly linked list, given only access to that node
  4. Regions cut by slashes

12/26/2018

  1. Generate all binary strings of length n with k bits set
  2. Print all paths from top left to bottom right of an n by m matrix moving only right and down
  3. 2-sum, 3-sum, 4-sum and variants
  4. Encode and decode strings

01/02/2019

  1. CTCI 1.1: Is unique
  2. CTCI 1.2: Check permutations
  3. CTCI 1.3: URLify
  4. CTCI 1.5: One away
  5. CTCI 1.6: String compression
  6. All possible full BSTs
  7. Range sum of BST
  8. Find itinerary (variant: return origin city)
  9. LRU cache
  10. CTCI 15.7: Multithreaded FizzBuzz

01/09/2019

  1. CTCI 4.1: Routes between nodes
  2. Save the Queen!
  3. Balanced parenthesis
  4. Combine fruits
  5. Find and replace in string
  6. Word break
  7. Best time to buy and sell stock

01/16/2019

  1. Decode String
  2. Binary parse trees
  3. Reverse Vowels in a String
  4. Valid parenthesis string
  5. Largest region in matrix
  6. Longest palindromic substring

nb_whiteboarding's People

Contributors

ggorlen avatar eugene-ma avatar elimisteve avatar juemura avatar danielrm88 avatar jerrytdev avatar

Watchers

James Cloos avatar  avatar

Forkers

etrepum

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.