```typescript
/** How many of each coin to hand back, largest coin first. */
export function tillFloat(amount: number, coins: number[]): number[] {
  const counts: number[] = [];
  let left = amount;
  for (const coin of coins.sort((a, b) => b - a)) {
    if (left >= coin) {
      counts.push(Math.floor(left / coin));
      left %= coin;
    }
  }
  return counts;
}
```