first draft

I'm not sure wether it's better to make contrib stuff by composition or iterative implementation.
Also haven't made tests yet since this is a first draft.

R.align may not be strictly "functional" style, but at least it doesn't mutate the arrays :smile: 
You can use R.curry here and get back a curried, 4-arity function