Interview Quiz

Questions: 16 · 10 minutes
1. A replicated store has N=3 copies, a successful write requires W=2 acknowledgments, and a read consults R=2 copies. Why can this configuration help a read encounter the latest acknowledged write, assuming completed quorum operations and proper version handling?
Because the read and write quorums must overlap when R + W is greater than N
Because every write is sent to exactly the same single replica
Because asynchronous networks always deliver writes in timestamp order
Because three replicas eliminate the possibility of node failure
2. A payment client retries a request after timing out, even though the first request may have succeeded. Which design most directly prevents a duplicate charge?
Increase the client timeout for every payment request
Place payment requests on a higher-priority network connection
Associate the operation with an idempotency key and reuse its recorded result
Create a new transaction identifier for every retry attempt
3. One database server can no longer hold a growing customer dataset or sustain its write volume. Which technique distributes different subsets of the data across multiple servers?
Replicating the complete dataset to read-only followers
Sharding the data by a suitable partition key
Adding a local in-memory cache to the existing server
Archiving the database transaction log more frequently
4. Users report occasional very slow requests, but average latency still looks healthy. Which metric would most directly expose the affected tail of the latency distribution?
The total number of database tables
The average response payload size
The number of application deployments
A high percentile such as p95 or p99 request latency
5. At the start of a system design interview, which action usually provides the best foundation for the architecture?
Draw the complete service diagram before discussing traffic
Select a database based on the technologies used by the interviewer
Clarify core use cases, expected scale, and important quality requirements
Begin by optimizing the component most likely to consume CPU
6. An online store's recommendation service becomes unavailable, but product details and checkout still work. Which response best demonstrates graceful degradation?
Reject every site request until recommendations recover
Delete recommendation data so the service restarts empty
Route checkout requests through the failed recommendation service
Show the core page without personalized recommendations or with a simple fallback
7. A highly popular cache entry expires, causing thousands of requests to recompute the same value simultaneously. Which technique most directly limits this cache stampede?
Give every request a different cache key
Disable caching whenever request volume rises
Move the cache and database onto the same machine
Coalesce concurrent misses so one request refreshes the value while others wait
8. An order service must update its database and publish an OrderCreated event. A crash between those actions could leave them inconsistent. Which pattern addresses this without requiring one distributed transaction across the database and broker?
Publish the event first and assume the later database write cannot fail
Write the order and an outbox record in one local transaction, then publish from the outbox
Run a periodic full-table export instead of recording events
Let each consumer create the original order record independently
9. A database frequently runs this query: WHERE tenant_id = ? AND created_at > ? ORDER BY created_at. Which composite index is generally the most suitable starting point?
An index on (tenant_id, created_at)
Separate indexes only on the primary key and display name
An index on an unrelated low-cardinality status column
An index on created_at followed by an unrelated display column
10. A request must pass through two independent components in sequence, and each has 99.9% availability. Approximately what is the combined availability, assuming both must work?
99.99%
99.9%
99.8001%
99.9999%
11. When cache nodes are added or removed, which property makes consistent hashing useful compared with a simple modulo assignment?
It ensures every node stores a complete copy of every value
It limits the proportion of keys that must be remapped
It sorts all cached values by their creation time
It guarantees identical load even when a few keys are extremely popular
12. A user updates a profile and immediately reads it back, but the read replica sometimes returns the old value because replication is asynchronous. Which response best provides read-your-writes behavior?
Temporarily route that user's post-update reads to the primary or a replica known to be current
Randomly choose a different replica for each immediate read
Cache the old profile for a longer period
Remove the version information from profile records
13. A product price is cached, but users must see a new price immediately after an administrator successfully updates it. Which approach most directly supports that requirement?
Increase the cache capacity so fewer products are evicted
Add more read replicas for the product database
Compress cached product records before storing them
Invalidate or update the cached product entry as part of the successful write flow
14. An image-processing service receives brief upload spikes that exceed the number of images its workers can process immediately. What is the main benefit of placing a durable queue between uploads and workers?
It guarantees that every image finishes processing at the same time
It buffers bursts and lets workers consume jobs at a sustainable rate
It removes the need to make processing operations retry-safe
It makes permanent storage of the uploaded images unnecessary
15. An API should allow occasional short bursts while enforcing an average request rate over time. Which rate-limiting algorithm naturally supports this behavior?
A token bucket with a defined refill rate and bucket capacity
A strict fixed delay before every accepted request
A permanent block after the first limit violation
A round-robin load balancer without request counters
16. A news site serves the same images and videos to users around the world. Which change most directly reduces delivery latency and origin traffic?
Store all media in the primary relational database
Send media requests through a single regional application server
Serve cacheable media through a geographically distributed CDN
Replace asynchronous replication with synchronous replication
Popular tests
Narcissistic Personality Inventory (NPI)
This self-report measure is used to assess narcissism as a personality trai…
Start Test
Yale-Brown Obsessive Compulsive Scale (Y-BOCS)
This measure is used to rapidly quantify the current severity of obsessive…
Start Test
CRAFFT Screening Test (CRAFFT 2.1)
This brief screening measure is designed to identify potential alcohol and…
Start Test
Patient Health Questionnaire-9 (PHQ-9)
This measure is commonly used to quickly screen for the presence and severi…
Start Test
Maslach Burnout Inventory (MBI)
This self-report measure is used to assess occupational burnout symptoms in…
Start Test
Adolescent Anxiety Questionnaire
This measure is designed to support a brief appraisal of anxiety symptoms a…
Start Test
Emotional Creativity Inventory (ECI)
This self-report measure assesses individual differences in the originality…
Start Test
Horne–Ostberg Morningness–Eveningness Questionnaire (MEQ)
Circadian preferences influence typical patterns of alertness and sleep tim…
Start Test
Ambivalent Sexism Inventory (ASI)
This measure is designed to assess attitudes toward women, including both o…
Start Test
Internalized Misogyny Scale (IMS)
This measure is designed to assess internalized negative beliefs and stereo…
Start Test
Perceived Stress Scale (PSS-10)
This self-report measure assesses the degree to which individuals appraise…
Start Test
Impulsive Behavior Scale (SUPPS-P)
Impulsivity is a multidimensional construct that is often assessed with bri…
Start Test
Clinical Institute Withdrawal Assessment for Alcohol, Revised (CIWA-Ar)
This rating scale is used to rapidly assess the severity of alcohol withdra…
Start Test
Positive and Negative Affect Schedule (PANAS)
This measure provides a brief self-report assessment of current or typical…
Start Test
Light Triad Scale (LTS)
This self-report measure assesses prosocial personality tendencies and orie…
Start Test
Suicidal Ideation Scale
In clinical settings, the Suicidal Ideation Scale is used to structure an i…
Start Test
Body Dysmorphic Disorder Scale (BDD-D)
This brief self-report measure is designed to screen for and quantify distr…
Start Test
Beck Anxiety Inventory (BAI)
This measure is a brief self-report inventory used to screen for anxiety sy…
Start Test
Differential Test of Perfectionism
This instrument is used to screen for perfectionism-related attitudes and t…
Start Test
Locus of Control Scale
This measure assesses generalized expectancies regarding the degree to whic…
Start Test
New Apathy Scale
This brief self-report measure is used to screen for apathy-related symptom…
Start Test
Perth Alexithymia Questionnaire (PAQ)
This measure assesses individual differences in alexithymia, including diff…
Start Test
Social Intelligence Scale
This brief self-report measure is designed to support rapid screening of in…
Start Test
Fear Test
This measure is designed to evaluate individual differences in fear-related…
Start Test
Neuroticism Level Scale
The measure is intended for brief screening of an individual’s propensity t…
Start Test
Aggressiveness Indicators Screening Questionnaire
This screening tool is designed to quickly identify behavioral indicators a…
Start Test