Jump Trading Interview Questions (2026-2027)
5 questions · 2 experiences · InterviewDB (5) · 1p3a (2)
Browse by role
Top topics
7 entries
Card Set Detection: Determine if a Hand of Cards Forms Valid Sets Under Custom Rules
Executable File Query Analyzer: SQL Queries on File Metadata with Aggregations
Networking and OS Conceptual Interview Questions: TCP, Processes, Memory, and Concurrency
Symbol Tracker: Track Declaration and Usage of Symbols Across a Codebase
User Creation Endpoint: Implement and Validate a REST API Endpoint for User Registration
Jumptrading Quantitative Research Internship HR and Technical Phone Interviews
Jumptrading Quant Developer Fulltime Tech Phone Screen Interview
Card Set Detection: Determine if a Hand of Cards Forms Valid Sets Under Custom Rules
Question Details
Problem
You are given a hand of cards. Each card has three attributes: color (red/green/blue), shape (oval/diamond/squiggle), and count (1/2/3). A valid "set" is any group of 3 cards where, for each attribute, the values across the 3 cards are either all the same or all different.
Given a list of cards, find all valid sets in the hand.
python
from dataclasses import dataclass
@dataclass
class Card:
color: str
shape: str
count: int
def find_sets(hand: list[Card]) -> list[tuple[Card, Card, Card]]:
...
Cards:
A=(red, oval, 1)
B=(green, oval, 2)
C=(blue, oval, 3)
D=(red, diamond, 2)
(A,B,C): color=all diff, shape=all same, count=all diff -> VALID SET
(A,B,D): color=all diff, shape=2 same 1 diff -> INVALID
**Output**: [(A,B,C)]
Follow-ups
- Your brute-force is O(n^3). For a 12-card layout, how many triples are there? Is O(n^3) acceptable in practice?
- How would you detect if a hand has NO valid set (used in the game to trigger a redeal)?
- Add a 4th attribute
fill(solid/striped/empty). How does this change your validity check? - Given that each attribute has 3 values and there are 4 attributes, what is the maximum deck size, and what is the expected number of sets in a random 12-card deal?
Topics
More from Jump Trading
People also viewed