Skip to content

Commit

Permalink
update README
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelficarra committed Jun 1, 2024
1 parent d062484 commit 448463b
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,10 @@ We should explore how to make this more ergonomic and functional.

## chosen solution

See the [November 2023 presentation to committee](https://docs.google.com/presentation/d/1wMUfikXIIz7woLN-5MbYbW8an40c8ZPrN1ehzWVf4zw).

A combination of variadic `Iterator.from` and `Iterator.prototype.flat`.
See the [June 2024 presentation to committee](https://docs.google.com/presentation/d/1gOs4UDAcaIF6Dc9z1qXus-ljizrRTSty5O-GbcM9NTs).

```js
let digits = Iterator.from(lows, [4, 5], highs);
let digits = Iterator.concat(lows, [4, 5], highs);
```

```js
Expand All @@ -56,7 +54,7 @@ function* p() {
yield Array(n).fill(n);
}
}
let repeatedNats = p().flat();
let repeatedNats = p().flatMap(x => x);
```

## considered design space
Expand Down

0 comments on commit 448463b

Please sign in to comment.