Stripe Coding & Algorithms Interview Questions
Practice the exact questions companies are asking right now.
Process auth requests with fraud rules
Question Implement a function that, given a list of Authorization Requests (timestamp_seconds, unique_id, amount, card_number, merchant), outputs a hu...
Convert bitmap into ASCII characters
Question Given an array/string of 0-1 bits representing a bitmap font, write code to render each character as a grid using '.' for 0 and '#' for 1, an...
Implement account scheduler with locking and LRU
Design a class AccountScheduler that manages the time-based availability of a fixed set of account IDs. Initialization You are given: - accounts: a li...
Find linked user records by similarity
You are given a list of user records. Each record has the following fields: - id (integer, unique) - name (string) - email (string) - company (string)...
Implement stateful connection router simulator
You are implementing a simplified connection router / load balancer for a Jupyter-like multi-tenant server system. There are N target servers, indexed...
Compute account balances with rejection and overdraft
You are given a list of transaction records as strings. Each record has the format: ` account_id,timestamp,currency,amount ` - account_id: string iden...
Implement JSON parsing and HTTP integration tasks
You are completing an “integration” exercise for a mapping service ("BikeMap"). You may use Google, but you must implement everything in code (you can...
Process Transactions and Compute Balances
You are given a list of financial transactions in CSV-like rows: ` account_name, timestamp, currency, amount ` - account_name is a string ID. - timest...
Implement streaming per-user reservoir sampling
Design and code (in Python) a streaming algorithm that ingests an unbounded event stream of tuples (user_id, event_time, event_type) and maintains, fo...
Plan bicycle routes on a city map
You are given a city bicycle network as a weighted graph where edges encode distance, bike-lane availability, elevation gain, and traffic risk. Comput...
Implement multi-part cost calculator
You are given a price catalog and a list of orders. Implement the following in any language (Python examples acceptable): Inputs - price_catalog: mapp...
Implement Luhn-based card validation and inference
Implement utilities for credit-card validation and inference using the Luhn algorithm. Card brands and formats: VISA — 16 digits, starts with 4; MASTE...
Implement multi-network card validator with Luhn
Design and implement a payment card validation module that supports multiple networks and error scenarios. Requirements: 1) Luhn checksum - Implement ...
Validate and infer credit cards with Luhn
Implement a credit-card validation suite using the Luhn algorithm and brand patterns. Brand patterns: - VISA: 16 digits, starts with 4 - MASTERCARD: 1...
Compute currency conversions with graphs and topological sort
You are given pairwise currency ratios such as "a:b = 1:1.5" and "b:c = 1:1.5". Design functions to: ( 1) store direct conversions; ( 2) answer querie...
Compute currency conversions with graph algorithms
Given a set of currency exchange relations such as 'A:B = 1:1.5' and 'B:C = 1:1.5' (meaning 1 A = 1.5 B and 1 B = 1.5 C), design algorithms and data s...
Design a subscription email scheduler with changes and renewals
Implement an email notification scheduler for subscription accounts. Inputs: - send_schedule: a mapping whose keys include: • "start": label to send...
Implement Card Validation and Recovery System
Question Design and implement a payment-card validation system supporting: Basic VISA validation (16-digit numbers starting with 4) using the Luhn che...
Validate Credit Card Numbers and Corrections
Question Q1. Given a credit-card number string, return whether it passes the Luhn checksum and, if valid, identify its brand among VISA (16 digits sta...
Implement tiered shipping calculator
Implement in JavaScript a shipping-cost calculator with three progressively richer pricing models based on a configuration object keyed by destination...