q: what is the streamish way to do this, if there is one:

look at a stream of items for a (hardwired in my case) criterion, returning the emptySet if they meet it, and the set of all of them if they don't?
N.B. I know how to do this w/o using stream-ish operations. I was just wondering if there's some sexy stream way.
I don't care about efficiency, either, or the optimal solution for my case. I am specifically asking a question about stream operations.
Another way to answer the question: is there a way to return early in the middle of a chain of stream operations?

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with GeePaw Hill

GeePaw Hill Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @GeePawHill

19 Apr
A couple of days back, I tweeted about SAFe. It created some stir on the timeline, which was great, as I got to see a lot of perspectives. I want to use that tweet as an excuse to talk about something much larger. This will be a long one. :)
Meanwhile, I remind you, geekery's not as important right now as some other things.

Please, stay safe, stay strong, stay angry, stay kind.

Black Lives Matter.

We are the only thing that can change this.
This muse is not really about SAFe for the most part, but about all of what the "methodology turn" in our trade produces. I do have one specific thing to say about SAFe, tho, so let's do that first and get it out of the way.
Read 44 tweets
17 Apr
A fable. This bird headed south too late, and flying along, froze its wings. Plummeting to the earth, it landed in a barnyard.
Sitting there, frozen, it bemoaned its wretched fate. Just then, a horse walked right over it, and the horse shat on the bird. And the bird, sitting in the warm manure, began to warm up.
And the bird, warming up, felt kind of cozy, so it began to chirp a little melody.

Barnyards got cats. And the cat, hearing the birdsong, investigated. It found the source, a pile of manure, and dove into it, pulling out the bird, and eating it.
Read 4 tweets
17 Apr
This, from the School Daze soundtrack, Morehouse College Glee Club, "I'm Building Me a Home".

I sing this to the trees sometimes. I sing most of this soundtrack to the trees sometimes.
In the rooms, ya know, they want you to have a higher power. It offends a lot of atheists, this idea, and to be fair, there's a lot of God talk in the rooms. I'm a committed atheist, a strict materialist atheist. But my higher power was easy to find: it's the music.
Read 4 tweets
17 Apr
Oh oh! "Suddenly Seymour", Movie OST cast.

My playlist is all about juxtaposition. Things pop up, outta nowhere.

This is a *stunning* take.
Tension & release. Rick's voice is clear and strong and simple. Ellen's in character, simpering Brooklyn.
Read 6 tweets
12 Apr
Standup Braindump

The standup is a short recurring meeting used to (re-)focus the team-mind on effectively moving stories through our workflow. Here's my recommended approach to having standups be useful and brief.
The general sequence is 1) address team-wide emergency issues, 2) work story-by-story, 3) distribute new work, 4) address team-wide non-emergency issues.

Note that, quite often, there is no part 1, and no part 4. Sometimes there's not even a part 3.

Some general tips, then.
1) Don't over-engineer standups. Stay relaxed with pep. Don't go telling people I said these were the rules. All meetings involve humans, and once humans are involved, we have to flex.
Read 21 tweets
11 Apr
The ultimate making app for a shipping multi-service system is actually a one-machine monolith with a UI. If your team is experiencing the most common pains from working in a large SOA environment, the productivity payback will be enormous.
It's important for me to take a second to remind you that there's much more to this world than geekery. Please keep working for change all around you, including, especially, outside the monitor.

Stay safe, stay strong, stay angry, stay kind.

Black Lives Matter.
We've talked a lot about the idea of having a shipping app for our customers and a making app for us. We can use the same source base to make multiple binaries. We target customer needs with one of those, and we target developer needs with the rest.
Read 43 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!

Follow Us on Twitter!