>>10
>Static typing is premature optimization
god no. it isn't implemented with optimization on mind, it is implemented with security in mind. (that you can use it for make the program go faster is not the primary concern)
>>type classes
>See above about types. The same functionality is available in Lisp nevertheless.
type-classes on lisp? you can use macros to archive something alike
>Monads are implementable in Lisp. But 90% of all use of monads in Haskell is to mimic practices that are easily expressible in everything else
true. lisp doesn't have the same design goal of haskell
>What if I don't know how many parameters will I want to supply to the function?
sigh. the list monad is also called the
indeterminism monad you specify the type of what are you receiving an then make the function process the list of arguments
integralPolinomio :: Double -> [(Double,Grado)] -> Double
integralPolinomio dif ass@(a:as) =
let gradoMayor = snd a
in dif * (sum $ map (uncurry integralMonomio) ass) / (moduloPolinomio gradoMayor)
look at the [(Double,Grado)] this is an umoptimized program (and a bad one) but it calculates by the legendre method integrals by accepting a list of arguments.