During previous session we captured in mind 3 transformations/conversions. While moving out from mathematical pressure we just got 3 simple formulas:
a) (A => B ) => (M[A] => M[B]) // Monad
b) (A => M[B] ) => (M[A] => M[B]) //Functor
c) (M [A => B]) => (M[A] => M[B]) //Applicative
As an implementation we've chosen functional way:
a) Func(A => B) : M[A] => M[B] // Monad
b) Func(A => Box[B]) : Box[A] => Box[B] //Functor
c) Func(Box[A => B]) : Box[A] => Box[B] //Applicative
a) (A => B ) => (M[A] => M[B]) // Monad
b) (A => M[B] ) => (M[A] => M[B]) //Functor
c) (M [A => B]) => (M[A] => M[B]) //Applicative
As an implementation we've chosen functional way:
a) Func(A => B) : M[A] => M[B] // Monad
b) Func(A => Box[B]) : Box[A] => Box[B] //Functor
c) Func(Box[A => B]) : Box[A] => Box[B] //Applicative