Search results

Jump to navigation Jump to search

Page title matches

Page text matches

  • parent s = father s `mplus` mother s grandparent s = paternalGrandfather s `mplus`
    561 bytes (71 words) - 08:43, 9 April 2021
  • parent s = (maybeToList (mother s)) ++ (maybeToList (father s)) grandparent s = (maybeToList (paternalGrandfather s)) ++
    631 bytes (63 words) - 08:44, 9 April 2021
  • newtype SuperState s t a = SuperState { runSuperState :: (s -> t -> (t,[(a,s)])) } instance Monad (SuperState s t) where
    1 KB (169 words) - 05:31, 9 March 2021
  • newtype State s a = State { runState :: s -> (a, s) } * <hask>s -></hask>
    380 bytes (24 words) - 12:26, 6 December 2023
  • parent s = (toMonad (father s)) `mplus` (toMonad (mother s)) grandparent s = (toMonad (parentalGrandfather s)) `mplus`
    1 KB (151 words) - 08:45, 9 April 2021
  • maternalGrandfather s = return s >>= \ms ->
    1 KB (147 words) - 08:41, 9 April 2021
  • newtype SupplyT s m a = SupplyT (StateT [s] m a) newtype Supply s a = Supply (SupplyT s Identity a)
    1 KB (202 words) - 05:09, 4 April 2014
  • maternalGrandfather s = return s >>= \ms ->
    4 KB (454 words) - 02:33, 7 January 2022
  • xor s t = if null s then t else s loop n s = cycle $ replicate (n-1) [] ++ [s]
    980 bytes (157 words) - 15:19, 6 February 2021
  • [s] <- getArgs putStrLn $ formatCalendarTime defaultTimeLocale s time
    543 bytes (78 words) - 15:19, 6 February 2021
  • ...e writings on the relevance of algorithmic information theory, and Chaitin's thoughts of its relatedness to epistemology, biology. [[Chaitin's construction]].
    440 bytes (57 words) - 06:23, 4 February 2016
  • It's very simple to use, and provides a highly efficient, pure interface * JeremyShaw's update of HalDaume's NewBinary package (Cabalized): http://www.n-heptane.com/nhlab/repos/NewBina
    2 KB (254 words) - 19:03, 23 October 2013
  • s/^> // s/\(\n\)> /\1/g
    600 bytes (99 words) - 10:10, 7 November 2013
  • ...e the prelude function for computing gcd's along with a test of the result's equality to one.
    329 bytes (49 words) - 19:43, 18 January 2014
  • .../github.com/bergey/diagrams-stow/blob/master/release/UpperBounds.hs Daniel's]) This page has ideas & requirements for building a less ad-hoc tool, whic Either Brent's tool or Daniel's (or both) performs each of the tasks listed above. In some cases the code
    2 KB (241 words) - 16:19, 22 June 2015
  • ...n if it is (mostly) backward-compatible, and otherwise in the "alternative(s)" column. !Module(s)
    5 KB (633 words) - 15:16, 6 February 2021
  • Page about the implementation of Oleg's Iteratee maintained by John Lato. * [http://okmij.org/ftp/Haskell/Iteratee Oleg's Original Implementation]
    2 KB (228 words) - 15:18, 6 February 2021
  • ...e hackathon on Friday and Saturday, and possibly Sunday afternoon if there's interest. To get sound you'll need VSTs, a VST host, and jack if it's linux. It's
    886 bytes (153 words) - 22:47, 5 April 2017
  • ! Author(s) ! Maintainer(s)
    4 KB (491 words) - 10:14, 3 August 2015
  • * <hask>unsafeInterleaveST :: ST s a -> ST s a</hask> * <hask>unsafeIOToST :: IO a -> ST s a</hask>
    1 KB (206 words) - 12:27, 8 June 2023
  • gray n = foldr (\s acc -> ("0" ++ s):("1" ++ s):acc) [] $ gray (n-1) gray' n = (gl . gr) [] where gl y = foldr (\s acc -> ('0':s):acc) y gp
    2 KB (298 words) - 03:02, 7 June 2021
  • (**) Calculate Euler's totient function phi(m). Euler's so-called totient function phi(m) is defined as the number of positive inte
    1 KB (224 words) - 19:44, 18 January 2014
  • ...nd raise the profile of the Haskell programming language. Most of all, it's fun---you get to tangibly experience your contributions in the form of beau
    1 KB (165 words) - 22:48, 5 March 2014
  • ...hs using graph canonization. It is somewhat of a slow solution, taking >10 s to run <hask>regular 6 3</hask>. [i : s | i <- n, s <- xs, i `notElem` s, asc (i : s)])
    2 KB (388 words) - 03:47, 10 January 2017
  • Because (State s) forms a monad, values can be combined with (>>=) or do{}. ...is a function from initial state s to final value a and final state s: (a,s). These are usually wrapped, but shown here unwrapped for simplicity.
    7 KB (1,055 words) - 15:06, 21 December 2018
  • 2007-03-01 closing=1403.17 change%=-0.25944346 cash=12389.992 assets=(#S(PURCHASE :AMOUNT 0.9840075 :ORIGINAL-PRICE 1399.04)) 2007-03-02 closing=1387.17 change%=-1.1402752 cash=12389.992 assets=(#S(PURCHASE :AMOUNT 0.9840075 :ORIGINAL-PRICE 1399.04))
    3 KB (309 words) - 16:40, 6 February 2015
  • .../notes-on-haskell.blogspot.com/2007/02/whats-wrong-with-for-loop.html What's wrong with for loops] ...blogspot.com/2007/02/whats-wrong-with-for-loop-revisited.html More on what's wrong with for loops]
    2 KB (160 words) - 08:56, 16 April 2020
  • This month's editorial is an encouragement to join the [http://www.haskell.org/mailman/l ...y, for example c2hs, Knit, and other projects require C parsers, but there's no common code base. Since parsers are one of the killer features of Haskel
    2 KB (241 words) - 22:48, 25 March 2017
  • #redirect [[Wadler's Law]]
    61 bytes (8 words) - 12:43, 8 June 2023
  • #redirect [[Poor man's here document]]
    73 bytes (10 words) - 11:48, 8 June 2023
  • #REDIRECT [[Haskell Quiz/Knight's Travails]]
    79 bytes (10 words) - 06:56, 8 June 2023
  • #redirect [[Haskell Quiz/Knight's Travails]]
    79 bytes (10 words) - 06:31, 8 June 2023
  • #redirect [[Xmonad/Config archive/Don's Config.hs]]
    86 bytes (12 words) - 04:31, 8 June 2023
  • #redirect [[Xmonad/Config archive/twifkak's Config.hs]]
    90 bytes (12 words) - 12:56, 8 June 2023
  • #redirect [[Xmonad/Config archive/Gwern's xmonad.hs]]
    88 bytes (12 words) - 13:01, 8 June 2023
  • #REDIRECT [[Xmonad/Config archive/leedo's xmonad.hs]]
    88 bytes (12 words) - 13:01, 8 June 2023
  • ...mation about <code>cabal new-build</code>, the main entry point into Cabal's new Nix-style local builds facility. * Haskell at Work's [https://haskell-at-work.com/episodes/2018-05-13-introduction-to-cabal.html
    592 bytes (78 words) - 15:19, 6 February 2021
  • == What's in the platform ==
    2 KB (260 words) - 13:28, 21 January 2020
  • #redirect [[Xmonad/Config archive/David Roundy's Config.hs]]
    95 bytes (13 words) - 13:00, 8 June 2023
  • [http://hackage.haskell.org/package/lens Edward Kmett’s <code>lens</code> package]. ''“JQuery for Haskell values”.'' ...s.Setter] ||<code>over setter f s</code> ||<code>setter %~ f $ s</code> ||modify pure value
    5 KB (742 words) - 19:22, 22 May 2022
  • #redirect [[Xmonad/Config archive/Thomas ten Cate's xmonad.hs]]
    98 bytes (14 words) - 13:00, 8 June 2023
  • monadic <hask>do</hask>-block. Here's some quick examples: s <- foldM fn [] [1..n]
    986 bytes (142 words) - 15:18, 6 February 2021
  • revWorker s [] = s revWorker s (x:xs) = revWorker (x:s) xs
    2 KB (333 words) - 12:44, 4 June 2018
  • ...being used in the wild, and discuss lessons learned about working with GHC's plugin mechanism. HERMIT is being used to optimize SYB traversals, to fuse Stream Fusion's concatMap combinator, and to implement staged compilation within GHC to gen
    1 KB (174 words) - 06:36, 16 September 2013
  • echo ${cpu} | gdbar -s v -h 15 -sw 1 >> /tmp/.dzen2cpugraph echo ${cpu cpu1} | gdbar -s p -w 7 -nonl
    924 bytes (169 words) - 15:18, 6 February 2021
  • ...in xmonad from ghci's main thread is another option, which requires xmonad's code to be modified slightly:
    1 KB (163 words) - 20:37, 8 February 2015
  • end s = (last s == n) && (length s /= 1)
    1 KB (153 words) - 06:29, 31 July 2021
  • where search :: STArray s Vertex Bool -> [Vertex] -> ST s [Tree Vertex]
    4 KB (488 words) - 04:24, 5 April 2024
  • Here's how Haskellers responded to the following question in the Call for Particip * Any, but I'd especially like to help people improve docs if that's welcome.
    1 KB (145 words) - 18:33, 27 January 2017
  • *All of the guts of MapReduce are hidden in the monad's <hask>bind</hask> function a -> ([(s,a)] -> [(s',b)])
    6 KB (1,053 words) - 03:27, 9 April 2021
  • ...to install diagrams of course cabal rejects the latest version. But here's where things go screwy: cabal then starts looking back in time to try to fi
    1 KB (207 words) - 15:18, 6 February 2021
  • ...ages.inf.ed.ac.uk/wadler/index.html#links Links] language and Steele et al's [http://lambda-the-ultimate.org/node/view/673 Fortress] language are effort ...patibility, exploring dark corners of [[GHC]], [[domain specific language]]s, and the [[Foreign Function Interface]].
    2 KB (239 words) - 22:47, 25 March 2017
  • * [[Bresenham's line drawing algorithm]]
    226 bytes (25 words) - 01:10, 26 April 2021
  • ...sed algebraic datatype|GADTs]]. One solution is to use [[existential type]]s. The example here is a solution to one of the exercises in Fun with [[phant compress (RPair s t) (x,y) = compress s x ++ compress t y
    8 KB (1,072 words) - 18:32, 16 January 2017
  • ...uncements regarding the provisional (as of Jan. 2012) Ireland Haskell User's Group will be posted here.
    247 bytes (34 words) - 15:19, 6 February 2021
  • , Run Com "uname" ["-s","-r"] "" 36000 , Run Date "%a %b %_d %Y %H:%M:%S" "date" 10
    1,023 bytes (104 words) - 15:18, 6 February 2021
  • This little piece of code computes an approximation of Riemann's zeta function, balancing the work to be done between N threads. zetaRange s (x,y) = [ fromIntegral n ** (-s) | n <- [x..y] ]
    4 KB (555 words) - 10:58, 22 June 2021
  • ...ne the greatest common divisor of two positive integer numbers. Use Euclid's algorithm. ...for ours. The function gcd' is a straightforward implementation of Euler's algorithm, and myGCD is just a wrapper that makes sure the arguments are po
    777 bytes (117 words) - 19:42, 18 January 2014
  • ...ent and return a result of that type". All universal quantifiers ("for all"s) must appear at the beginning of a type. ...e, even inside normal datatypes like lists or <tt>Maybe</tt>. The GHC User's Guide gives the following example:
    2 KB (347 words) - 11:46, 4 February 2023
  • This is intended as a beginner's tutorial for learning Haskell from a "Let's just solve things already!" point of view. The examples should
    6 KB (842 words) - 05:27, 8 February 2016
  • Since f is not a pure function, it's f :: x -> y -> m c. The correct form would be instance Idiomatic i f g => Idiomatic i (s -> f) (i s -> g) where
    2 KB (365 words) - 18:50, 19 September 2017
  • instance (MonadReader s m, Functor m) => MonadReader s (ListT m) where instance (MonadState s m, Functor m) => MonadState s (ListT m) where
    2 KB (402 words) - 06:31, 12 May 2015
  • ...conal/talk-2014-bayhac-denotational-design/blob/master/README.md this talk's README on GitHub].
    298 bytes (41 words) - 05:35, 23 May 2014
  • This has a problem however, that the [[constructor]]s of type ''Resistor'' are data S a = S a
    9 KB (1,351 words) - 18:21, 6 June 2020
  • ...e uncompilable). That page already has source for the bot anyway, so there's not much point in keeping this separate one.
    284 bytes (52 words) - 00:57, 17 June 2015
  • but when it's used in case expressions: Could the GHC example benefit from some more list-comprehension syntax? Let's borrow a new reserved word:
    6 KB (743 words) - 02:12, 5 August 2021
  • ...ight look like this: <hask>\x -> x + 1</hask>. (That backslash is Haskell's way of expressing a &lambda; and is supposed to look like a Lambda.) .../ foldr</hask>. So if I wanted to add one to each element of a list, here's one way to do it (without anonymous functions):
    2 KB (296 words) - 06:56, 12 April 2021
  • identifier s = identifier' s 'l' identifier' (c:s) t = (match c t) && or [identifier' s b | (a, b) <- fsm, a == t]
    2 KB (346 words) - 03:47, 10 January 2017
  • ...ve, however, is the ''wrong one'' for what we're trying to do here. So let's change the order of the arguments of the helper: Believe it or not, we're almost done! How is that? Let's parenthesize a bit for emphasis:
    5 KB (891 words) - 14:21, 3 January 2018
  • f :: s -> (a,s) f :: State s a
    4 KB (716 words) - 07:41, 26 January 2019
  • newtype DRMonad e s w a = DRMonad {runDRMonad :: s -> (Either e a,s,w)} instance (Monoid m, Error e) => Monad (DRMonad e s w) where
    6 KB (995 words) - 23:51, 16 April 2021
  • Here's a simple test for object orientation (for some reasonable definition): ...Haskell's <tt>[[Dynamic]]</tt>, where you only have to deal with <tt>B</tt>s that are instances of <tt>Typeable</tt>. But even with that, note that <tt>
    4 KB (587 words) - 11:16, 28 March 2018
  • ...GPU's. It's about unsupervised machine learning. Later: Convolutional RBM's. || Markus Liedl || BSD3 || https://github.com/haskell-munich/accelerate-rb
    3 KB (355 words) - 14:25, 30 May 2015
  • ...Moreover it is able to interface with third party EDA tools such as Altera's [http://www.model.com/ Modelsim] and [http://www.altera.com/products/softwa :David J. King and John O'Donnell's digital circuit simulator
    2 KB (333 words) - 11:47, 4 November 2014
  • The following is a list of previous documents and discussions about Haskell's module system: * Iavor S. Diatchki et al's formal specification of the Haskell 98 module system: http://purely-functio
    3 KB (368 words) - 22:21, 24 February 2016
  • ...fine, but alas not always. Perhaps this is a deficiency in GHC, but here's one way it can happen: What's going on? GHC knows, from the type signature that <tt>x::a</tt>. Then appl
    4 KB (716 words) - 11:30, 24 January 2016
  • ...sing from the ordering of external events to a functional language. Burton's technique uses abstract values contained in an (theoretically) infinite str ...d with <code>contents</code> to retrieve the abstract <code>Decision</code>s for use by <code>choice</code>:
    2 KB (341 words) - 09:18, 22 February 2022
  • | Holiday Inn Express, Penn's Landing | Holiday Inn Express, Penn's Landing
    1 KB (190 words) - 14:59, 21 October 2016
  • ...convert the problem to the equivalent problem for n > 0 by adding the list's length to n. | otherwise = let (f,s) = splitAt n xs in s ++ f
    3 KB (474 words) - 20:35, 23 May 2021
  • * <code>ST s a</code>, the type of encapsulated-state actions. The condition that an action's effects only occur if performed prevents their use in otherwise-ordinary Ha
    3 KB (428 words) - 04:08, 12 April 2024
  • For now we refer to Wikipedia's article about [http://en.wikipedia.org/wiki/Type_class type classes].
    322 bytes (46 words) - 10:06, 3 August 2015
  • As an illustration, let's take the function <haskell>div :: Int -> Int -> Int -- which is actually But there's more going on here than immediately meets the untrained eye. It could be a
    4 KB (669 words) - 02:17, 3 November 2023
  • Lazy Mom : Here's a credit card, Son. Just charge what you need. from myself. What's the use pretending I'm getting them from you?
    3 KB (445 words) - 15:19, 6 February 2021
  • toHTML s = MkHTML s fromHTML (MkHTML s) = s
    5 KB (887 words) - 06:53, 12 June 2023
  • ...hask> keyword with <hask>data</hask> and it'll still compile, indeed there's even a good chance your program will still work. The converse is not true, newtype State s a = State { runState :: s -> (s, a) }
    6 KB (1,007 words) - 15:57, 22 May 2016
  • ...utation of type <code>Cont r s</code>. That's a bit brain-twisting, so let's think about how we might do it... ...is going to receive a question <code>q</code> about a value of type <code>s</code>, and has to answer it somehow.
    7 KB (1,253 words) - 23:34, 25 June 2021
  • Let's untangle that, and then test the referentially transparent isolation. Let's use QuickCheck. First we need an Arbitrary instance for
    8 KB (1,214 words) - 00:46, 23 October 2017
  • = GHC's switch from darcs to git =
    571 bytes (77 words) - 18:50, 18 June 2014
  • Here's one to show it done in a fold just for the fun of it. Do note that it is le Here's one that does half as many compares:
    2 KB (320 words) - 00:08, 8 July 2019
  • Spare {frameScore=s} -> [[s-10]] Strike {frameScore=s,next=10} -> [[10],[s-20]]
    4 KB (555 words) - 15:19, 6 February 2021
  • ...S crew have made some good progress on creating a new target for GHC so it's doable at least. ...has proven that these can indeed be encoded with the current state of GHC's type features.
    2 KB (405 words) - 10:31, 9 February 2019
  • True, there's lot of right association, too, but bad enough. * Donald Bruce Stewart's [http://hackage.haskell.org/package/dlist difference list library]
    3 KB (421 words) - 16:40, 1 August 2018
  • Since there's already syntactic sugar for ranges, there's usually no reason to define a function like 'range' in Haskell. In fact, th
    1 KB (214 words) - 02:08, 5 April 2014
  • ...ad use the <code>at</code> function to construct <code>Located Trail</code>s.
    2 KB (297 words) - 06:13, 3 August 2013
  • There's lot of advocacy at [[ThingsToAvoid/Discussion]] which may be moved to here.
    322 bytes (47 words) - 03:29, 14 August 2021
  • 8 iunie 2007 S-a primit de la domnul conf M. Gontineac stirea despre continuarea unor cerc ...subiecte de pe fiecare bilet s-au referit la Haskell. Toti studentii care s-au prezentat la examen au trecut cu succes examenul.
    3 KB (399 words) - 14:50, 18 February 2015
  • ...an error message and make a note of the exception code. Look at Microsoft's [https://msdn.microsoft.com/en-us/library/cc704588.aspx NTSTATUS values pag ...[https://www.gnu.org/software/gdb/ GNU debugger] to see the debug message(s).
    1 KB (221 words) - 23:10, 28 January 2016
  • instance VarMonad (ST s) (STRef s) where ...
    1 KB (198 words) - 22:52, 21 July 2021
  • s
    853 bytes (146 words) - 04:26, 26 April 2021
  • Haskell's FFI is used to call functions from other languages (basically C at this poi ...] stuff. I could implement the whole tcgetattr / tcsetattr thing, but let's just turn ICANON on and off, so IO.getChar doesn't wait for a newline:
    2 KB (331 words) - 12:45, 17 February 2015

View (previous 100 | next 100) (20 | 50 | 100 | 250 | 500)