2つの長い実行中のプロセスをHaskellの2つの別々のスレッドで計算したいとします。しかし、私は最初のものからの結果だけを気にします。どうすればいい?最初のスレッドの結果を取得
例(擬似コード):
thread1 = spark $ long_running some_arg1
thread2 = spark $ long_running some_arg2
result = first_done thread1 thread2 -- Maybe even first_done [thread1, thread2]?
これは私が探していたものです。ありがとう! – bheklilr