[Haskell] ARRAY 2023 Call for Papers - please help disseminate

2023-02-08 Thread Troels Henriksen
# ARRAY 2023 - co-located with PLDI 2023 - call for papers * Submission deadline: 31st of March * Notification:21st of April * Workshop date: 17th of June * Submission: https://array23.hotcrp.com/ Array programming is at home in many communities, including language design, library d

[Haskell] Help lead Haskell: Executive Director sought for Haskell Foundation

2020-12-07 Thread Richard Eisenberg
Posting on behalf of the Haskell Foundation Working Group. Please forward widely! The Haskell Foundation is seeking an Executive Director. Please find the job description here: https://haskell.foundation/ ed-job-description

[Haskell] Help wanted: Postfix admin guru for Haskell.org

2019-11-09 Thread Gershom B
me concentrated help from someone familiar with maintaining and administering postfix servers, if someone is up to volunteer for the task. Thanks! --Gershom ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell

[Haskell] Help inform GHC's development priorities

2018-10-18 Thread Ben Gamari
tl;dr. Please a take a minute to express your thoughts on GHC's development priorities via this survey [1]. Hello everyone, The GHC developers want to ensure that we are working on problems that of most importance to you, the Haskell community. To this end we are surveying the community [

[Haskell] [ANN] Help wanted: Vty contributors on Windows

2017-01-20 Thread Jonathan Daugherty
Hi, With some recent requests for Windows support in Vty[1], I'm looking for folks who are interested in working on the Vty library and getting it working on Windows (Cygwin) systems. Anyone interested in contributing should contact me! Thanks, [1] http://hackage.haskell.org/package/vty -- J

Re: [Haskell] [Haskell-cafe] Help wanted with Wiki.Haskell.Org

2015-04-21 Thread Yitzchak Gale
Gershom wrote: > ...the HaskellWiki ...requires care and maintenance > and contributions from all of us. I replied to this in the reddit thread at: http://www.reddit.com/r/haskell/comments/339qxm/haskellcafe_help_wanted_with_wikihaskellorg/ Short summary: > 1) Account Creation Management I bel

[Haskell] Help wanted with Wiki.Haskell.Org

2015-04-20 Thread Gershom B
would be worth investigating if a full upgrade and new plugins could help this issue. In the meantime, the responsibility for creating new accounts has fallen on only one person for years. This is not a good situation. We would like to set up a mail alias for wiki admins and extend account

Re: [Haskell] [Haskell-cafe] Short survey re: use of haskell.org funds to drive development -- please help!

2014-03-04 Thread Tyler Huffman
Collecting Money) to best benefit the > open-source Haskell community. You can help us by filling out a very > short survey (it should only take you about 5 minutes): > > > https://docs.google.com/forms/d/1rEobhHwFpjzPnra9L1TmrozWNFFyAVNPmdUMCcT--3Q/viewform > > Please do fil

[Haskell] Short survey re: use of haskell.org funds to drive development -- please help!

2014-03-04 Thread Brent Yorgey
The haskell.org committee is trying to figure out how to use some of its newfound power (the Power of Collecting Money) to best benefit the open-source Haskell community. You can help us by filling out a very short survey (it should only take you about 5 minutes): https://docs.google.com

[Haskell] Just started working with Haskell. Need some help

2014-01-18 Thread Pyro Crane
Hi, I just started working with Haskell Running it on a RHEL linux operating system I was able to download and install it, along with libraries and packages (or, at least, what I thought were the libraries and packages) But, when I try to run a simple script, I keep getting the error : "C

[Haskell] A Ph.D. Student’s CRY for Help

2013-02-16 Thread Rasheed Khan
A Ph.D. Student’s CRY for Help To: Prof. Hamid Arabnia, WORLDCOMP Coordinator, Professor of Computer Science, University of Georgia, USA Prof. Hamid Arabnia, I am a student from Africa and I am in the final stages of my Ph.D. work. I have a journal paper in ACM and a conference paper in

[Haskell] Haskell Functions Help

2011-02-03 Thread Manolache Andrei-Ionut
I need help with two functionsfirst this is the curent code :http://pastebin.com/UPATJ0r ->Function 1)removeTautologies :: Formula->Formula If in a clause, a literal and its negation are found, it means that the clause will be true, regardless of the value finally assigned t

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-19 Thread Malcolm Wallace
Frank Rosemeier wrote: Than I can try to transfer the Yarrow homepage until the end of January. Just to note that I have taken the three or so minutes that was necessary to transfer all of the Yarrow website to a new location here: http://projects.haskell.org/yarrow Frank, as soon as

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-15 Thread Hudak, Paul
> -Original Message- > From: Frank Rosemeier [mailto:fr...@rosemeier.info] > Sent: Tuesday, December 14, 2010 8:23 AM > To: Hudak, Paul > Cc: Thomas Schilling; Ian Lynagh; Haskell; Wogahn, Mark > Subject: Re: [Haskell] Please help me to reconstruct the Yarrow > website! Re: N

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-14 Thread Taral
On Mon, Dec 13, 2010 at 8:01 AM, Hudak, Paul wrote: > My research group is paying $200/month to maintain the old haskell.org at > Yale, and we cannot continue doing this indefinitely -- indeed, I had hoped > that we could have turned off the machine by now.  I propose that we shut > down the ol

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-14 Thread Frank Rosemeier
Behalf Of Frank Rosemeier Sent: Sunday, December 12, 2010 10:30 AM To: Thomas Schilling Cc: Ian Lynagh; Haskell Subject: Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server Hello Thomas, thank you very much for this link! I am glad that the Yarrow website is

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-13 Thread Hudak, Paul
: [Haskell] Please help me to reconstruct the Yarrow > website! Re: New haskell.org server > > > Hi Paul, > > On Mon, Dec 13, 2010 at 11:01:49AM -0500, Hudak, Paul wrote: > > > > indeed, I had hoped that we could have turned off the machine by now. > > Sorry it&

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-13 Thread Ian Lynagh
Hi Paul, On Mon, Dec 13, 2010 at 11:01:49AM -0500, Hudak, Paul wrote: > > indeed, I had hoped that we could have turned off the machine by now. Sorry it's taken us so long to get there. > I propose that we shut down the old server on Jan 31, 2011. We were actually talking about this last night

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-13 Thread Axel Simon
0 AM To: Thomas Schilling Cc: Ian Lynagh; Haskell Subject: Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server Hello Thomas, thank you very much for this link! I am glad that the Yarrow website is accessible. I will try to move it to the community server as soon a

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-13 Thread Don Stewart
> > -Original Message- > > From: haskell-boun...@haskell.org [mailto:haskell-boun...@haskell.org] > > On Behalf Of Frank Rosemeier > > Sent: Sunday, December 12, 2010 10:30 AM > > To: Thomas Schilling > > Cc: Ian Lynagh; Haskell > > Subject: Re: [H

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-13 Thread John Smith
On 13/12/2010 18:01, Hudak, Paul wrote: Dear All: My research group is paying $200/month to maintain the old haskell.org at Yale, and we cannot continue doing this indefinitely -- indeed, I had hoped that we could have turned off the machine by now. I propose that we shut down the old server

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-13 Thread Hudak, Paul
an Lynagh; Haskell > Subject: Re: [Haskell] Please help me to reconstruct the Yarrow > website! Re: New haskell.org server > > Hello Thomas, > > thank you very much for this link! > I am glad that the Yarrow website is accessible. > I will try to move it to the community s

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-12 Thread Frank Rosemeier
12:23, Frank Rosemeier wrote: Dear Haskellers, today I have noticed that the link http://www.haskell.org/yarrow is broken! Who is responsible or can help me to reconstruct the Yarrow home page? To my mind this it is not a fair treatment of the Yarrow wersite: I asked in September for prolong

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-11 Thread Duncan Coutts
ew URL, (wherver you move the new site to, e.g. somewhere on community.haskell.org) so there is no need for old links to be broken. To make such a request, see: http://community.haskell.org/admin/ Of course that does not help with the issue of moving stuff over, but if it's just static content th

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-11 Thread Taral
On Sat, Dec 11, 2010 at 6:52 AM, Frank Rosemeier wrote: > As I mentioned in my mail thirty days are not enough for me to realize such > a change. Seriously? You can't make changes to your site in 30 days? You're getting completely fair treatment -- everyone got the same notice, and you're the on

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-11 Thread Frank Rosemeier
Hello Malcolm, As I mentioned in my mail thirty days are not enough for me to realize such a change. It has not been mentioned how long the old website will be available. Please help me to obtain a fair treatment for the Yarrow website! Is there any chance to obtain an account for the old

Re: [Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-10 Thread Thomas Schilling
; today I have noticed that the link > http://www.haskell.org/yarrow > is broken! > Who is responsible or can help me to reconstruct the Yarrow home page? > To my mind this it is not a fair treatment of the Yarrow wersite: > I asked in September for prolongation of this website, >

[Haskell] Please help me to reconstruct the Yarrow website! Re: New haskell.org server

2010-12-10 Thread Frank Rosemeier
Dear Haskellers, today I have noticed that the link http://www.haskell.org/yarrow is broken! Who is responsible or can help me to reconstruct the Yarrow home page? To my mind this it is not a fair treatment of the Yarrow wersite: I asked in September for prolongation of this website, than I

Re: [Haskell] Help-me read file

2010-10-18 Thread kahl
> I have a file with 100 lists, with 100 ints. > > I have to read the file and apply the map and sort functions on lists. > > II did it to read file: > > learquivo :: FilePath -> IO ([[Int]]) > learquivo s = do >            conteudo <- readFile s >            return (read conteudo) >

Re: [Haskell] Help-me read file

2010-10-18 Thread Henning Thielemann
On Mon, 18 Oct 2010, Gilmara Pompelli wrote: Hello I have a file with 100 lists, with 100 ints. I have to read the file and apply the map and sort functions on lists. II did it to read file: learquivo :: FilePath -> IO ([[Int]]) learquivo s = do            conteudo <- readFile s            

[Haskell] Help-me read file

2010-10-18 Thread Gilmara Pompelli
Hello I have a file with 100 lists, with 100 ints. I have to read the file and apply the map and sort functions on lists. II did it to read file: learquivo :: FilePath -> IO ([[Int]]) learquivo s = do            conteudo <- readFile s            return (read conteudo) But now applying the sort

[Haskell] Some help in operator precedence

2010-03-07 Thread Edgar Z. Alvarenga
I created a simple program in Haskell to simulate the Physics Ising model (http://en.wikipedia.org/wiki/Ising_model) with Metropolis algorithm: http://haskell.pastebin.com/Zt0gguEa And used Data.Vector.Unboxed.Mutable to model de 2D grid. To this a used a unidimensional vector, but created a op

Re: [Haskell] Help with cabal and windows

2009-05-30 Thread Duncan Coutts
On Sat, 2009-05-30 at 09:06 -0700, newuser21 wrote: > Hi, I am new to haskell. BTW, in future it's better to ask these kinds of questions on the haskell-cafe mailing list. These days the main haskell mailing list is mostly for announcements etc. > I have an programm whitch i want to compile for w

[Haskell] Help with cabal and windows

2009-05-30 Thread newuser21
form under wine and tryied to build the program. Thanks newuser -- View this message in context: http://www.nabble.com/Help-with-cabal-and-windows-tp23790447p23790447.html Sent from the Haskell - Haskell mailing list archive at Nabble.com. ___ Haske

Re: [Haskell] Google Summer of Code Help and suggestions

2009-03-25 Thread Brent Yorgey
On Thu, Mar 26, 2009 at 02:18:54AM +1930, Maria Gabriela Valdes wrote: > Hi, my name is Maria Gabriela Valdes, i'm a new member of the mailing list, > but i'm not new using haskell. Currently i'm studying computer science in > Venezuela. > > I'm writing because i want to know more about de haskell

[Haskell] Google Summer of Code Help and suggestions

2009-03-24 Thread Maria Gabriela Valdes
Hi, my name is Maria Gabriela Valdes, i'm a new member of the mailing list, but i'm not new using haskell. Currently i'm studying computer science in Venezuela. I'm writing because i want to know more about de haskell community. I'm looking foward to knowing a lot of knew people and learing a lot

Re: [Haskell] Help : data & concurrent packages

2009-01-13 Thread Thorkil Naur
Hello, On Tuesday 13 January 2009 18:26, bft wrote: > Hi ! > Can someone tell me where to download the *data* and *concurrent *packages. I recall data and concurrent packages from some years back, but I would assume that they are merged into the base package nowadays where GHC-6.10.1 is the lat

[Haskell] Help : data & concurrent packages

2009-01-13 Thread bft
Hi ! Can someone tell me where to download the *data* and *concurrent *packages. I need them to build FranTk1.1 package ( http://www.dcs.gla.ac.uk/~meurig/FranTk/news.html) Thanks in advance! BFT frantk.conf file : Package {name = "FranTk", import_dirs = ["/local/www.people/personal/meuri

Re: [Haskell] Re: Help : A problem with IO

2008-11-27 Thread abdullah abdul Khadir
Thanks all, I got it working finally. What did i learn ? a) I need to put a do after else for more than one instruction (?) b) All similar type of questions are to be redirected to haskell-beginner and haskell-cafe Points noted. Thank you once again, Abdullah Abdul Khadir On Wed

Re: [Haskell] Re: Help : A problem with IO

2008-11-26 Thread Chris Eidhof
On 26 nov 2008, at 17:18, abdullah abdul Khadir wrote: Hi, The function getMyLine written by me is intended for getting a complete string from the standard input. import IO getMyLine :: IO [Char] getMyLine = do c <- getChar if(c == '\n')

Re: [Haskell] Re: Help : A problem with IO

2008-11-26 Thread Axel Simon
Hi Abdullah, On Wed, 2008-11-26 at 21:48 +0530, abdullah abdul Khadir wrote: > Hi, > > The function getMyLine written by me is intended for getting a > complete string from the standard input. > > import IO > > getMyLine :: IO [Char] > getMyLine = do > c <- getChar >

[Haskell] Re: Help : A problem with IO

2008-11-26 Thread abdullah abdul Khadir
Hi, The function getMyLine written by me is intended for getting a complete string from the standard input. import IO getMyLine :: IO [Char] getMyLine = do c <- getChar if(c == '\n') then return "" elsecs <-

[Haskell] Help : A problem with IO

2008-11-26 Thread abdullah abdul Khadir
Hi, getMyLine :: IO [Char] getMyLine = do c <- getChar if(c == '\n') then return "" elsecs <- getMyLine return [c] ___ Haskell mailing

[Haskell] Need help with VXML again (fun deps and forall types)

2008-11-02 Thread Marc Weber
Some time I've announced that I'm working on VXML, a validating xml library. The use case which makes trouble is elem+ (one or more) This example is encoded in this way: root -> St 1 id :1 endable : True a -> St 1 b -> St 1 c -> St 12 id :11 endable : True (a|b|c) -> St

Re: [Haskell] [Haskell-cafe] Help with polymorphic functions

2008-05-09 Thread Brandon S. Allbery KF8NH
On 2008 May 9, at 8:28, Abhay Parvate wrote: Of course in the final code many people would recommend that you put in the type declarations as a good form of documentation, and it may be also more specialized according to your usage than what the compiler/interpreter will deduce. It's a

Re: [Haskell] [Haskell-cafe] Help with polymorphic functions

2008-05-09 Thread Abhay Parvate
You can also drop the type signature and see what type deduction you get in ghci :) Your program would have compiled well without the type signature! It's also a good exercise to come up with the most general type of a function that you write, and then compare it with the type that is deduced by dr

Re: [Haskell] [Haskell-cafe] Help with polymorphic functions

2008-05-08 Thread Wei Yuan Cai
Thank you all for the help. This was most helpful. Regards, Weiyuan On Fri, May 9, 2008 at 8:16 AM, Brett G. Giles <[EMAIL PROTECTED]> wrote: > Hi Wei > > Haskell needs to know that it can legally apply the function "shift". > So, as requested, you need to add co

Re: [Haskell] [Haskell-cafe] Help with polymorphic functions

2008-05-08 Thread Ross Mellgren
You gave test a type signature which gives "a" universal quantification, which means in this case that "a" is something, but you can't do anything in particular to it (since you don't know anything about it). shift has the signature a -> Int -> a, but it's within the type class Bits: Pr

[Haskell] [Haskell-cafe] Help with polymorphic functions

2008-05-08 Thread Wei Yuan Cai
Hello, I'm having some trouble with a polymorphic function using another polymorphic function within. A simplified code of what I'm trying to do is as follows: main = print $ test 1 8 test :: a -> Int -> a test x n = shift x n I get the following compilation error: Could not deduce (Data.Bits.

[Haskell] Re: please HELP me to understand this code:| quickly:((

2008-02-13 Thread Stefan Monnier
> I fear our alacritous Neil will now be the unwilling recipient of Haskell > porn and Nigerian bank scams... :( M Haskell porn! Stefan ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell

Re: [Haskell] please HELP me to understand this code:| quickly:((

2008-02-12 Thread Dan Weston
Neil Mitchell wrote: Hi This mailing list should be used mainly for announcements, not requests for help - for that see [EMAIL PROTECTED] You might also want to read up on homework help, and how to ask the right questions to get the right answers: http://www.haskell.org/haskellwiki/Homework_he

Re: [Haskell] please HELP me to understand this code:| quickly:((

2008-02-12 Thread Neil Mitchell
Hi This mailing list should be used mainly for announcements, not requests for help - for that see [EMAIL PROTECTED] You might also want to read up on homework help, and how to ask the right questions to get the right answers: http://www.haskell.org/haskellwiki/Homework_help In addition

[Haskell] please HELP me to understand this code:| quickly:((

2008-02-12 Thread xxxyyyzzz
(tomorrow I have an exam :|..and I really don't like what I see:P ) http://www.nabble.com/file/p15443214/haskell.jpg -- View this message in context: http://www.nabble.com/please-HELP-me-to-understand-this-code%3A%7C-quickly%3A%28%28-tp15443214p15443214.html Sent from the Haskell - Ha

[Haskell] help needed to test new GLFW package

2007-12-20 Thread Paul L
With the new Cabal 1.2, it's now possible to make platform dependent C code compilation. So I've made available new version of GLFW that follows standard Cabal installation steps, it's at: http://www.cs.yale.edu/homes/hl293/download/GLFW-0.2.tar.gz Note that this is VERY experi

[Haskell] need some help with type inference

2007-11-15 Thread Hal Daume III
Hi Haskellers -- It's been a while since I've frequented this list, but I'm hoping I can stir up some help. My problem isn't Haskell-specific (so please forgive the blanket email), but it *is* related to something written in Haskell, so hopefully that's sufficient

Re: [Haskell] help with IOArray

2007-08-19 Thread Bulat Ziganshin
Hello robert, Sunday, August 19, 2007, 6:52:59 PM, you wrote: > I defined > newMem s = newIOArray (0, size-1) 0 > and then > x = newMem 30 i recommend you to read http://haskell.org/haskellwiki/IO_inside -- Best regards, Bulatmailto:[EMAIL PROTECTED] _

Re: [Haskell] help with IOArray

2007-08-19 Thread Bertram Felgenhauer
robert bauer wrote: > I have an IOArray, but it doesn't work the way I expected it to. > > I defined > > newMem s = newIOArray (0, size-1) 0 > > and then > > x = newMem 30 > > then > > do { >y <- x > ; v <- readIOArray y 2 > ; print v > ; writeIOArray y 2 20 > ; v <- readIOArray y 2 >

[Haskell] help with IOArray

2007-08-19 Thread robert bauer
I have an IOArray, but it doesn't work the way I expected it to. I defined newMem s = newIOArray (0, size-1) 0 and then x = newMem 30 then do { y <- x ; v <- readIOArray y 2 ; print v ; writeIOArray y 2 20 ; v <- readIOArray y 2 ; print v } this resulted in 0, 2 as expected. howeve

Re: [Haskell] Please help!!!

2007-06-09 Thread Stefan O'Rear
l > > tira :: [Int] -> Int > tira []=0 > tira [x]=x Spelling out names like 'mdcl' and 'tira' will make it easier for us to help you. gcd isn't a problem because it is well established mathematical notation, but the others are opaque to me. Stefan ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell

Re: [Haskell] Please help!!!

2007-06-09 Thread AVG
But i tried and i don't know waht is wrong. -- View this message in context: http://www.nabble.com/Please-help%21%21%21-tf3895195.html#a11043217 Sent from the Haskell - Haskell mailing list archive at Nabble.com. ___ Haskell mailing list Ha

Re: [Haskell] Please help!!!

2007-06-09 Thread Stefan O'Rear
On Sat, Jun 09, 2007 at 12:22:02PM -0700, AVG wrote: > > What's wrong?? > > greatest common divisor > > code: > > > > mdc :: Int-> Int -> Int > mdc _ 1 = 1 > mdc 1 _ = 1 > mdc x y > |x > y = mdc (x-y) y > |y > x = mdc (y-x) x > |x==y = x > > mdcl :: [Int]-> [Int] > mdcl []=[] > mdcl l = mdcl

[Haskell] Please help!!!

2007-06-09 Thread AVG
[Int] -> Int gcdl l = tira l tira :: [Int] -> Int tira []=0 tira [x]=x -- View this message in context: http://www.nabble.com/Please-help%21%21%21-tf3895195.html#a11042870 Sent from the Haskell - Haskell mailing list archive at Nabble.com. ___ Ha

Re: [Haskell] Newbie help with type-classes

2007-05-11 Thread Derek Elkins
Ryan Ingram wrote: [EMAIL PROTECTED] is better for this type of question. Follow-up is set to it. Here's a test case for the problem I'm having; I'm using runhaskell from ghc v6.6. Problem #1) Without -fallow-undecidable-instances, I get the following error: Constraint is no smaller

Re: [Haskell] Newbie help with type-classes

2007-05-11 Thread Bas van Dijk
Maybe this is not what you want, but you can also put the 'convl' function in the 'ConvertToInt' class. class ConvertToInt a where conv :: a -> Int convl :: [a] -> [Int] With this approach you don't need any language extension. regards, Bas van Dijk On 5/11/07, Ryan Ingram <[EMAIL PROTEC

Re: [Haskell] Newbie help with type-classes

2007-05-11 Thread Bas van Dijk
Add: -fallow-overlapping-instances to your OPTIONS pragma and read about overlapping instances in the GHC User Guide: http://www.haskell.org/ghc/docs/latest/html/users_guide/type-extensions.html#instance-overlap regards, Bas van Dijk On 5/11/07, Ryan Ingram <[EMAIL PROTECTED]> wrote: Here's a

[Haskell] Newbie help with type-classes

2007-05-10 Thread Ryan Ingram
Here's a test case for the problem I'm having; I'm using runhaskell from ghc v6.6. Problem #1) Without -fallow-undecidable-instances, I get the following error: Constraint is no smaller than the instance head in the constraint: ConvertToInt a (Use -fallow-undecidable-instances to permi

Re: [Haskell] help -- need a random number

2007-04-26 Thread Marc A. Ziegert
that is exact the way, how i had learned about the state monads like IO and Maybe. that was even before i understood the [] monad, folding and using Random; i don't remember when that was... ghc-5.xx age. in my opinion, unsafePerformIO is a good learning tool, as soon as you use it tricky to an

Re: [Haskell] help -- need a random number

2007-04-26 Thread Johannes Waldmann
import System.IO.Unsafe (unsafePerformIO,unsafeInterleaveIO) Whoa! I'd be very cautious recommending these for newbies ... ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell

Re: [Haskell] help -- need a random number

2007-04-26 Thread Marc A. Ziegert
module Dice where import System.Random import System.IO.Unsafe (unsafePerformIO,unsafeInterleaveIO) import Data.List (unfoldr) dice4,dice6,dice8,dice10,dice12,dice20,dice666 :: [Int] dice4 = randomRs (1,4) (read "foo"::StdGen) dice6 = randomRs (1,6) (mkStdGen 5) dice8 = randomRs (1,8) (unsafePerf

Re: [Haskell] help -- need a random number

2007-04-26 Thread Johannes Waldmann
I need some random numbers. in the IO Monad, hiding the use of a generator do x <- randomRIO (0, 1 :: Double) ; print x you can also make the state explicit: do g0 <- getStdGen ; let { ( x, g1 ) = randomR ( 0, 1::Double) g0 } ; print x a RandomGen is actually the state object for the ge

[Haskell] help -- need a random number

2007-04-26 Thread robert bauer
Hi, I need some random numbers. The documentation identifies StdGen, but I can't figure out how to invoke it. The documentation is great in every way, except an actual example that I can essentially cut and paste. Thanks ___ Haskell mailing list Has

Re: [Haskell] Help needed interrupting accepting a network connection

2006-12-04 Thread Bjorn Bringert
On 2 dec 2006, at 22.13, Cat Dancer wrote: I'd like to write a server accepting incoming network connections that can be gracefully shutdown. When the server is asked to shutdown, it should stop accepting new connections, finish processing any current connections, and then terminate. Clients c

Re: [Haskell] Help needed interrupting accepting a network connection

2006-12-03 Thread Chris Kuklewicz
After more testing I found an ugly problem that a child could be killed before the finally installed the handler that calls (putMVar doneMVar ()) Thus I have added slightly more paranoid code to ensure that the child is running before exposing the (T)MVar/ThreadId to the rest of the application.

Re: [Haskell] Help needed interrupting accepting a network connection

2006-12-03 Thread Chris Kuklewicz
I realized there is another problem, since my code holds onto the ThreadId's the thread data structures may or may not be getting garbage collected and for a long running server the list of children grows without bound. So I changed it to periodically clean out the finished child threads from th

Re: [Haskell] Help needed interrupting accepting a network connection

2006-12-03 Thread Chris Kuklewicz
Cat Dancer wrote: >> > I'd certainly be most happy not to use asynchronous exceptions as the >> > signalling mechanism, but how would you break out of the accept, >> > except by receiving an asynchronous exception? >> >> Short Version: You trigger a graceful exit using a TVar... >> ...and then you

Re: [Haskell] Help needed interrupting accepting a network connection

2006-12-02 Thread Chris Kuklewicz
Cat Dancer wrote: > On 12/2/06, Chris Kuklewicz <[EMAIL PROTECTED]> wrote: >> Hi, I have taken a crack at this. The best thing would be not to use the >> asynchronous exceptions to signal the thread that calls accept. > > I'd certainly be most happy not to use asynchronous exceptions as the > sig

Re: [Haskell] Help needed interrupting accepting a network connection

2006-12-02 Thread Cat Dancer
On 12/2/06, Chris Kuklewicz <[EMAIL PROTECTED]> wrote: Hi, I have taken a crack at this. The best thing would be not to use the asynchronous exceptions to signal the thread that calls accept. I'd certainly be most happy not to use asynchronous exceptions as the signalling mechanism, but how wo

Re: [Haskell] Help needed interrupting accepting a network connection

2006-12-02 Thread Chris Kuklewicz
Hi, I have taken a crack at this. The best thing would be not to use the asynchronous exceptions to signal the thread that calls accept. And use STM more, since the exception semantics are much easier to get right. But a few minor changes gets closer to what you want. First, the main problem yo

[Haskell] Help needed interrupting accepting a network connection

2006-12-02 Thread Cat Dancer
I'd like to write a server accepting incoming network connections that can be gracefully shutdown. When the server is asked to shutdown, it should stop accepting new connections, finish processing any current connections, and then terminate. Clients can retry if they attempt to make a connection

[Haskell] help with happy/alex

2006-11-22 Thread robert bauer
27;t match. I've attached the .y and .x files. Also, I cannot figure out what I need to do in the parser to call the lexer and I don't know how to kick start the parser -- I have no clue what to put in third, main.hs, module. Any help would be appreciated. TVScriptParser.y Desc

[Haskell] HaskellWiki Style Help

2006-11-15 Thread Ashley Yakeley
If you're interested in improving the CSS for HaskellWiki, please go to . The only requirements are knowledge of CSS and an ability to use MediaWiki. More than one person would be ideal. At Simon PJ's request, I have also turned

Re: [Haskell] Homework help (was: 2 programs VERY URGENT)

2006-08-13 Thread Brett G. Giles
kell.org/hawiki/HomeworkHelp > > Please direct people asking for homework help in the wrong way to > this page. Thanks! > > (Oh, one more thing. This page should probably get migrated over to > hswiki. Any takers?) > > Cheers, > Andrew Bromage > _

[Haskell] Homework help (was: 2 programs VERY URGENT)

2006-08-13 Thread ajb
ping up here. This and more, covered here: http://haskell.org/hawiki/HomeworkHelp Please direct people asking for homework help in the wrong way to this page. Thanks! (Oh, one more thing. This page should probably get migrated over to hswiki. Any take

Re: [Haskell] Can anyone help...

2005-11-28 Thread Jerzy Karczmarczuk
I apologize for the posting in which I mention the inadequacy of Doaitse Swierstra partition program, it has been commented by others, and the thread is obsolete. But my posting (issued immediately then) got delayed by the moderator because of the schizoidal nature of my e-mail address... Sorry.

Re: [Haskell] Can anyone help me with partition numbers?

2005-11-28 Thread Jerzy Karczmarczuk
Doaitse Swierstra wrote: Or (since we started to do someone's homework anyway) generate 0 = [[]] generate n = [x:rest | x <- [1..n], rest <- generate (n-x)] Unless I am misled, this will generate the *unordered* partitions, e.g., for n=7, 64 of them, not 15. Jerzy Karczmarczuk _

Re: [Haskell] Can anyone help me with partition numbers?

2005-11-25 Thread Jan van Eijck
On Fri, Nov 25, 2005 at 10:29:48AM +0100, Tomasz Zielonka wrote: > On Thu, Nov 24, 2005 at 05:52:23PM +0100, Jan van Eijck wrote: > > Like so: > > > > generatePs :: (Int,[Int]) -> [[Int]] > > generatePs (n,[]) = [take n (repeat 1)] > > generatePs (n,(x:xs)) = > > (take n (repeat 1

RE: [Haskell] Can anyone help me with partition numbers?

2005-11-25 Thread E. Zuurbier (Erik)
Doaitse, For generate 4 this gives a.o. three equivalent solutions: [1,1,2], [1,2,1] and [2,1,1]. I guess the ultimate idea would be to prune permutations. Regards Erik Zuurbier Onderwerp: Re: [Haskell] Can anyone help me with partition numbers? Or (since we started to do someone's hom

Re: [Haskell] Can anyone help me with partition numbers?

2005-11-25 Thread Salvador Lucas
This does not work properly: Main> generate 5 [[1,1,1,1,1],[1,1,1,2],[1,1,2,1],[1,1,3],[1,2,1,1],[1,2,2],[1,3,1],[1,4],[2,1,1,1],[2,1,2],[2,2,1],[2,3],[3,1,1],[3,2],[4,1],[5]] You need to add something else: parts 0 = [[]] parts n = [m:p | m<-[1..n], p<-parts (n-m), (null p || m<=head p)] Main

Re: [Haskell] Can anyone help me with partition numbers?

2005-11-25 Thread Doaitse Swierstra
Or (since we started to do someone's homework anyway) generate 0 = [[]] generate n = [x:rest | x <- [1..n], rest <- generate (n-x)] Doaitse Swierstra On 2005 nov 25, at 10:29, Tomasz Zielonka wrote: On Thu, Nov 24, 2005 at 05:52:23PM +0100, Jan van Eijck wrote: Like so: generatePs :: (I

Re: [Haskell] Can anyone help me with partition numbers?

2005-11-25 Thread Tomasz Zielonka
On Thu, Nov 24, 2005 at 05:52:23PM +0100, Jan van Eijck wrote: > Like so: > > generatePs :: (Int,[Int]) -> [[Int]] > generatePs (n,[]) = [take n (repeat 1)] > generatePs (n,(x:xs)) = > (take n (repeat 1) ++ (x:xs)) : generatePs (pack (x-1) ((n+x),xs)) > where > pack :: Int ->

Re: [Haskell] Can anyone help me with partition numbers?

2005-11-25 Thread Jan van Eijck
+2, 1+4, 2+3 and 5. Define a > function parts which returns the list of distinct partitions of an integer n. > For example, parts 4 = [[1,1,1,1],[1,1,2],[1,3],[2,2],[4]]. > -- > Sent from the Haskell - Haskell forum at Nabble.com: > http://www.nabble.com/Can-anyone-help-me-with-part

[Haskell] Can anyone help me with partition numbers?

2005-11-24 Thread whoals (sent by Nabble.com)
A partition of a positive integer n is a representation of n as the sum of any number of positive integral parts. For example, there are 7 partitions of the number 5: 1+1+1+1+1, 1+1+1+2, 1+1+3, 1+2+2, 1+4, 2+3 and 5. Define a function parts which returns the list of distinct partitions of an integ

RE: [Haskell] Re: help with some basic code that doesn't work

2005-03-03 Thread Simon Peyton-Jones
ruary 2005 05:32 | To: haskell@haskell.org | Cc: [EMAIL PROTECTED] | Subject: [Haskell] Re: help with some basic code that doesn't work | | Malcolm Wallace <[EMAIL PROTECTED]> wrote: | > Just a comment, since a couple of people have made similar statements. | > Haskell will derive

Re: [Haskell] Re: help with some basic code that doesn't work

2005-02-14 Thread Tomasz Zielonka
On Mon, Feb 14, 2005 at 12:36:22PM +0100, Remi Turk wrote: > > Now that this topic is brought up... > > > > Occasionally I would need to define recursive datatypes > > using an explicit fixed-point operator, such as: > > > > > data Fix f = In (f (Fix f)) deriving (Show, Eq) > > > data L a x

Re: [Haskell] Re: help with some basic code that doesn't work

2005-02-14 Thread Remi Turk
On Mon, Feb 14, 2005 at 02:31:54PM +0900, Shin-Cheng Mu wrote: > Malcolm Wallace <[EMAIL PROTECTED]> wrote: > >Just a comment, since a couple of people have made similar statements. > >Haskell will derive Eq for arbitrarily complex types - there is no > >restriction to "simple" types, whatever they

Re: [Haskell] Re: help with some basic code that doesn't work

2005-02-13 Thread kahl
Shin-Cheng Mu <[EMAIL PROTECTED]> wrote: > > Occasionally I would need to define recursive datatypes > using an explicit fixed-point operator, such as: > > > data Fix f = In (f (Fix f)) deriving (Show, Eq) > > data L a x = Nil | Cons a x deriving (Show, Eq) > > However, Haske

[Haskell] Re: help with some basic code that doesn't work

2005-02-13 Thread Shin-Cheng Mu
Malcolm Wallace <[EMAIL PROTECTED]> wrote: Just a comment, since a couple of people have made similar statements. Haskell will derive Eq for arbitrarily complex types - there is no restriction to "simple" types, whatever they might be. Now that this topic is brought up... Occasionally I would need

Re: [Haskell] help with some basic code that doesn't work

2005-02-08 Thread Karl Hasselström
On 2005-02-07 20:36:55 +, pablo daniel rey wrote: > data Dir = Left | Right | Up | Down > data Piece = Vertical | Horizontal | CodeA | CodeB > > the error i get : > > Instances of (Eq Dir, Eq Piece) required for definition of chgDir You try to compare Dir and Piece values without having told

Re: [Haskell] help with some basic code that doesn't work

2005-02-08 Thread Malcolm Wallace
Matthew Walton <[EMAIL PROTECTED]> writes: > (==) works on types which are members of the Eq typeclass. You can > define this instance manually, or, since your type is nice and simple, ^^ > you can get Haskell to derive it for

Re: [Haskell] help with some basic code that doesn't work

2005-02-08 Thread Matthew Walton
pablo daniel rey wrote: hello i'm new to haskell so i'm sorry if this is a stupid question, but i'm having problems with some basic code. the code : data Maybe Dir = Just Dir | Nothing data Dir = Left | Right | Up | Down data Piece = Vertical | Horizontal | CodeA | CodeB flow = [(Horizontal, Left,

  1   2   3   >