Entradas

Mostrando entradas de mayo, 2018

libro de haskel

http://www.cs.us.es/~jalonso/publicaciones/Piensa_en_Haskell.pdf operaciones con lenguajes haskel

haskel

https://prezi.com/hiv3o__liagm/laboratorio-de-sintaxis-y-semantica-de-los-lenguaje module EntradaSalida (     leerLenguaje ) where     import System.IO leerLenguaje :: IO [String] leerLenguaje = do     putStr "Ingresar el nombre del archivo: "     archivo <- getLine     handle <- openFile archivo ReadMode     contents <- hGetContents handle     putStr (contents ++ "\n")     let palabras = lines contents       hClose handle     return palabras main :: IO () main = do     putStr "Obtener palabras del lenguaje: \n "     palabras <- leerLenguaje     putStr (show palabras) ----------------------------------------------------------------------------- --  -- Módulo   :  Actividad Laboratorio 1 - Ejercicio 1 -- Copyright:  (c) Sintaxis y Semántia de los Lenguajes - FRT - UTN 2014 --...

haskel evaluativo

prom :: Float -> Float -> Float ->Float prom a b c = (a + b + c)/3 vol :: Float -> Float vol r = (4 * 3.14 * r^3)/3 areac :: Float -> Float areac r = 3.14 * r^2 interpar :: [ Int ] -> [Int ] -> [ Int ] interpar [ x1, x2 ] [ y1, y2 ] = [ x1, y1, x2, y2] ultima :: Integer -> Integer ultima x = rem x 10 rotacion :: [ Integer] -> [ Integer ] rotacion xs = tail xs ++ [head xs] rango :: [ Integer] -> [ Integer ] rango x = [ minimum x, maximum x] palindromos :: [ Integer ] -> Bool palindromos x = x == reverse x

ard ver video

arduino proy

fisica2

FISICA2