solulubeta
Sign in
Story Problems / Arrays, windows & two pointers
01.06 · Problem

Lifeboats

Medium Sort + two pointers (greedy pairing) Pro

This problem is part of solulu Pro

After a flood, people of different weights must be rescued. Each boat carries at most two people and a total weight of at most limit (every person alone weighs ≤ limit). What is the minimum number of boats needed?

Lifetime ₹2,000 ₹1,000 · Beta offer
Mark this problem as solved when you are finished.

Item 6 of 94 · updated 2026-10-12