Question: map a list of functions expecting two input values.

Hi there. Thank you all in advanced.

The general question is how to pass a pair of values to a list of functions that expect that pair of values as input.
I already know this solution for passing a list of values to a list of functions that expect one value as input.

map(eval~,[f(x),g(x)],x=~[p,q,t])

Well f(x) and g(x) take every element of the list, but what if f(x) and g(x) expect two values. The concrete case is to pass p and q to iquo and irem. The following were my tries:

  • map(eval~,[iquo(x),irem(x)],x=[p,q])
  • map(eval~,[iquo(x),irem(x)],x=(p,q))
  • map(eval~,[iquo(op(x)),irem(op(x))],x=[p,q])

I searched and found some partial related topics in the site but not quite with this approach.

 

Please Wait...