Mock Coding Interview with a Slack Engineer
Watch a full mock coding interview with a Slack software engineer, covering two classic algorithm problems from start to finish. This anonymous phone screen on interviewing.io features a new-grad candidate tackling Pow(x, n) and Maximum Subarray — two of the most frequently asked coding interview questions at top tech companies. The warm-up problem is implementing exponentiation using a divide-and-conquer approach that runs in O(log n) time, handling edge cases like negative exponents and zero. The main problem is finding the maximum sum of any contiguous subarray, solved with Kadane's algorithm in O(n) time. The candidate walks through brute-force thinking, optimizes to the efficient solution, writes clean Python code, and builds a thorough test suite. The interviewer provides real-time feedback on communication, problem-solving approach, and time management. The candidate scores a perfect 4 out of 4 on all evaluation categories — problem solving, technical communication, code quality, and testing — and advances to the next round. Whether you are preparing for FAANG phone screens or practicing algorithm fundamentals, this video shows exactly what a successful coding interview looks like under realistic conditions. 0:00 Introduction and interview setup 0:55 Candidate background discussion 2:30 Problem 1: Implement Pow(x, n) — problem statement 3:05 Brute force approach and optimization insight 4:05 Recursive divide-and-conquer strategy 5:10 Handling negative exponents 6:45 Even vs odd exponent cases 8:20 Coding the solution in Python 12:10 Handling negative base values 13:10 Testing and edge cases for Pow(x, n) 15:25 Running test cases and debugging 19:15 Problem 2: Maximum Subarray Sum — problem statement 20:20 Identifying the maximum subarray by inspection 21:20 Naive O(n^2) approach discussion 24:00 Key insight: resetting negative running sums 26:15 Arriving at Kadane's algorithm (O(n) solution) 27:30 Coding the solution in Python 30:15 Verifying with the original example 31:00 Writing additional test cases (all negative, empty array, all positive) 33:00 Interviewer feedback and tips on time management Problem links: - Pow(x, n) on LeetCode: https://leetcode.com/problems/powx-n/ - Maximum Subarray on LeetCode: https://leetcode.com/problems/maximum-subarray/
Download
1 formatsVideo Formats
Right-click 'Download' and select 'Save Link As' if the file opens in a new tab.