Skip to main content

Posts

Showing posts from February, 2013

Haskell tutorial

Important link for tutorial =================== http://www.haskell.org/haskellwiki/Haskell_in_5_steps#Where_to_go_from_here http://www.cs.nott.ac.uk/~gmh/book.html http://rigaux.org/language-study/syntax-across-languages-per-language/Haskell.html http://learnyouahaskell.com/chapters You can change prompt by :set prompt 0. how to run/quit haskell file =============================== a. ghci  ( it will load Glasgow Haskell Compiler) b. load file >  :l filename.hs c. fncInsideFile parameter d. :quit  1.  bracket Issues in ============= fnc(a)  // wrong fnc a ;// right, parameters are space seperated Parentesis a. for tuple  -- let tup = ( 1, "sss") b. (x:xs) -- x is first element, xs is rest elements c.   for curry function/section. if you don't use () it will not work -- correct useSection     = (/2) -- Incorrect useSection     = /2 instead of using 1 + 2     use   (+) 1 2  Square Bracket : for List -- let lst = [1,2]

Ghostscript pdf merge split

1. Cut range of page/ split  pages from pdf ========================= gs -sDEVICE=pdfwrite -dNOPAUSE -dBATCH -dSAFER -dFirstPage=3 -dLastPage=7 -sOutputFile=out.pdf   in.pdf 2. Merge multiple pdfs ================ gs -dBATCH -dNOPAUSE -q -sDEVICE=pdfwrite -dPDFSETTINGS=/prepress -sOutputFile=out.pdf in1.pdf in2.pdf