Reported September 2026
Airbnbhash table

Superhost Eligibility

Reported by candidates from Airbnb's online assessment. Pattern, common pitfall, and the honest play if you blank under the timer.

Get StealthCoderRuns invisibly during the live Airbnb OA. Under 2s to a working solution.
Founder's read

Airbnb reported this one in September 2026, and it looks scarier than it is. Superhost Eligibility is a group-by problem in disguise. Parse each string, bucket by host, then check three thresholds. If you've got an OA invite for Airbnb this week, expect parsing and boundary traps, not a clever algorithm. Walk in knowing it's a hash map with counters, a final filter, and a sort. If you blank on the day, StealthCoder runs invisibly as a safety net, but you probably won't need it once you've seen this shape.

The problem

Each listing record is host rating recent. rating is an integer hundredths score and recent is 1 when the listing has a review in the required recent period, otherwise 0.
Return sorted hosts having at least minListings listings, average rating at least minAverageRating, and at least minRecentPercent percent recent listings.

Function
qualifyingSuperhosts(listings: String[], minListings: int, minAverageRating: int, minRecentPercent: int) → String[]

Examples
Example 1
listings = ["a 490 1","a 480 1","a 470 1","b 500 1","b 500 1"]
minListings = 3
minAverageRating = 475
minRecentPercent = 90
return = ["a"]
A has enough listings, average 480, and all are recent; B lacks listings.
Example 2
listings = ["x 500 1","x 500 0","x 500 1"]
minListings = 3
minAverageRating = 450
minRecentPercent = 90
return = []
Only two thirds of X's listings are recent.
Example 3
listings = ["z 400 1"]
minListings = 1
minAverageRating = 400
minRecentPercent = 100
return = ["z"]
All inclusive thresholds are met exactly.

Constraints
1 <= listings.length <= 2 * 10^5.
Ratings and thresholds are nonnegative integers; recent is 0 or 1.
0 <= minRecentPercent <= 100.

Reported by candidates. Source: FastPrep

Pattern and pitfall

The trick: keep three numbers per host in a hash map. Listing count, rating sum, and recent count. One pass over the input, then filter and sort the host names. The pitfall is floating point. Don't compute averages or percents as doubles. Use cross-multiplication instead: sumRating >= minAverageRating * count, and recentCount * 100 >= minRecentPercent * count. All thresholds are inclusive, and Example 3 tests exactly that. Watch overflow too. With 2 * 10^5 listings and ratings that could be large, use 64-bit integers for sums and products. Sort the qualifying host names lexicographically before returning. Splitting each string on spaces is simple, but don't assume the host name contains digits only. Complexity is O(n + h log h) where h is the number of hosts. If the live OA throws a variant and your mind goes blank, StealthCoder is the hedge sitting quietly on your screen.

Drill it cold or hedge it with StealthCoder. Either way, don't walk into the OA hoping you remember the trick.

If this hits your live OA

You can drill Superhost Eligibility cold, or you can hedge it. StealthCoder runs invisibly during screen share and surfaces a working solution in under 2 seconds. The proctor sees the IDE. They don't see what's behind it. Made for the candidate who got the OA invite this morning and has 72 hours, not six months.

Get StealthCoder

Related leaked OAs

⏵ The honest play

You've seen the question. Make sure you actually pass Airbnb's OA.

Airbnb reuses patterns across OAs. Made for the candidate who got the OA invite this morning and has 72 hours, not six months. Works on HackerRank, CodeSignal, CoderPad, and Karat.

Superhost Eligibility FAQ

What's the trick in the Airbnb Superhost Eligibility problem?+

It's aggregation. Use a hash map from host to listing count, rating sum, and recent count. One pass builds it. Then you filter hosts against the three thresholds and sort the names. There's no hidden algorithm, just careful arithmetic and parsing.

How do I avoid floating point errors on the average and percent checks?+

Cross-multiply with integers. Check ratingSum >= minAverageRating * count and recentCount * 100 >= minRecentPercent * count. That keeps every comparison exact, so boundary cases like Example 3 pass without rounding surprises. Use 64-bit types to be safe.

Are the thresholds inclusive?+

Yes. Example 3 has a host with rating 400 against a minimum of 400 and 100 percent recent against a minimum of 100, and it qualifies. Use >= for all three checks, including minListings.

How hard is this really for an Airbnb OA?+

Easy to medium. The logic is a single pass with a map, so the difficulty is in being careful, not clever. Most failures come from float math, forgetting to sort, or off-by-one on the inclusive thresholds.

How do I prepare for this in 48 hours?+

Practice string parsing and hash map aggregation until you can write them without thinking. Then write this one from scratch, test the three given examples, and add edge cases: one listing, all non-recent, and minRecentPercent of 0. Also confirm your output order is sorted.

Problem reported by candidates from a real Online Assessment. Sourced from a publicly-available candidate-aggregated repository. Not affiliated with Airbnb.

OA at Airbnb?
Invisible during screen share
Get it