Pa

Parallel and/or with short-circuit in Elixir

Hacker News

Parallel and/or with short-circuit in Elixir

Hi, this can terminate when either branch of and/or terminates early and short-circuits the operator. def or_(task1, task2) do parent = self pid1 = spawn(fn -> send parent, task1.() end) pid2 = spawn(fn -> send parent, task2.() end) receive do false -> receive do result2 -> Process.exit pid1, :kill Process.exit pid2, :kill result2 end true -> Process.exit pid1, :kill Process.exit pid2, :kill true end end https://gist.github.com/roehst/e98a9b0703ceb75d85f7b212b60005ee

Share card

Actual performance

2points
Did not reach leaderboard

Launch Intel predictions

Analyze your own launch →
Hacker NewsStrong engagement from HN community · Strong signals: 000 · Missing: https docs, excited, just released
53%53% predicted probability of success on Hacker News, based on ML models trained on real launch data.
nativeThis product was originally launched on this platform.
Product HuntOn track for Day 1 leaderboard · Missing: mac, agents, macos
51%51% predicted probability of success on Product Hunt, based on ML models trained on real launch data.
Indie HackersIH features products with proven revenue · Strong signals: para · Missing: supports, reddit linkedin, podcasting
39%39% predicted probability of success on Indie Hackers, based on ML models trained on real launch data.
TrustMRRLess likely to generate early MRR · Strong signals: para · Missing: mobile apps, ios, personal
31%31% predicted probability of success on TrustMRR, based on ML models trained on real launch data.
AppSumoMay struggle as an AppSumo deal · Missing: plus, platform, intuitive
30%30% predicted probability of success on AppSumo, based on ML models trained on real launch data.
BetaListMay not resonate with beta-testers · Missing: web3, chat, crypto
25%25% predicted probability of success on BetaList, based on ML models trained on real launch data.
Acquire.comPre-revenue stage for this audience · Missing: arr, mrr, revenue
21%21% predicted probability of success on Acquire.com, based on ML models trained on real launch data.

Incorrect prediction on native model

Similar products

A
A Parallel Implementation of Graph2Vec45%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

A Parallel Implementation of Graph2Vec

Hacker News53
A
A Parallel Implementation of Graph2Vec45%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

A Parallel Implementation of Graph2Vec

Hacker News3
Pa
Parallel Gospel48%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Parallel Gospel

Hacker News1
So
Sorts – parallel radix- and quicksort in Go48%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Sorts – parallel radix- and quicksort in Go

Hacker News2
Mo
Modeling parallel (and hierarchical) agents with Burr50%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Modeling parallel (and hierarchical) agents with Burr

Hacker News2
Ab
Abstract Calculus, a massively parallel model of computation44%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Abstract Calculus, a massively parallel model of computation

Hacker News5
WI
WIP] Zephyr NN Jax FrameworkL Short, Simple, Declarative49%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

WIP] Zephyr NN Jax FrameworkL Short, Simple, Declarative

Hacker News1
AP
API for dig +short43%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

API for dig +short

Hacker News1
Ax
Axiom v2.0 – Parallel Ingestion at 125M rows/SEC47%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Axiom v2.0 – Parallel Ingestion at 125M rows/SEC

Hacker News1
Ka
Kaleidoscope – A Parallel AI Agent TUI32%Launch Intel prediction score: how likely this product is to succeed on its source platform, based on its name, tagline, and description.

Kaleidoscope – A Parallel AI Agent TUI

Hacker News2