PayPal Coding Interview Questions
25 PayPal coding interview problems with full optimal solutions — 16 easy, 6 medium, 3 hard. Every problem ships with multiple approaches (brute-force first, then the optimal), complexity tables for each, company-specific tips on what an PayPal interviewer values, and a FAQ section.
Showing 5 problems of 25
- #1easyfrequently asked
1. Two Sum
Given an array of integers and a target, return indices of the two numbers that add up to the target. PayPal asks this to gauge whether you reach for a hash map immediately — the same reflex they want when you're matching a payment to a pending invoice by amount.
- #2easyfrequently asked
2. Valid Parentheses
Given a string of brackets, decide whether they are balanced. PayPal asks this as a stack-comfort warm-up — the same data structure that powers their transaction-state-machine stack for rollback on failed payments.
- #3easyfrequently asked
3. Merge Two Sorted Lists
Merge two sorted linked lists into one sorted list by splicing nodes together. PayPal asks this as a warm-up to gauge pointer comfort — the same primitive they use when merging two sorted streams of authorized and captured payments by timestamp.
- #12easyfrequently asked
12. Maximum Depth of Binary Tree
Find the maximum depth of a binary tree. PayPal uses this as a recursion litmus — the same primitive they use to measure the depth of a chain of related transactions when investigating circular fraud rings.
- #15easyfrequently asked
15. Best Time to Buy and Sell Stock
Find the maximum profit from a single buy-sell transaction in a price array. PayPal treats this as a core financial-reasoning problem — interviewers look for candidates who can frame it as tracking running minimum and maximum gain.
Related interview-prep guides
Codility for Tech Interviews in 2026: The Complete Guide for Candidates
Codility is the dominant algorithmic-assessment platform across European tech hiring. Heavy in the UK, Germany, Netherlands, Nordics, and Poland where the company was founded. It scores candidates on both correctness and time complexity, runs 60-to-120-minute timed tests, and ships three products: Tests, CodeCheck, and CodeLive. This guide is what 2026 candidates need to know.