F# currying - 使用两个参数调用

F# currying - calling with two parameters

我有问题,可以简化为以下示例:

let func a b c = printf "%s %s %s" a b c
let partial = func "a"

let something_that_returns_two_parameters = "b", "c" // what to write here?

something_that_returns_two_parameters |> partial // what to write here?

我的预期结果是使用 "a" "b" "c" 调用 func。 我可以编辑最后两行。 这可以通过某种方式实现吗?

您需要使用 ||> 运算符应用元组:

something_that_returns_two_parameters ||> partial

此运算符将元组的每个组件应用于函数。

参考F# operators