Don't knock it! Using a functional language helped you to think about the
problem in a new way, and throw together a prototype that worked in a short
enough time that you actually did it. A merit of fp is, I think, that you can
explore the algorithm design space much more quickly -- and algori
"Aditya Siram" <[EMAIL PROTECTED]> wrote:
> I have been trying to install Hat for the last couple of days but GHC
> does not recognize it as a package. I compiled 2.05 from source, but
> at the 'make install' step I see this error message:
>
> Installing hat package for ghc under
> /usr/loca
In #haskell on freenode we had a discussion about isPrefixOf, which is
probably implemented roughly as so:
isPrefixOf [] _ = True
isPrefixOf _ [] = False
isPrefixOf (x:xs) (y:ys) = x == y && isPrefixOf xs ys
Well, this is basically just a zip with a special base case. But you
can't just write i
Hi
Maybe this is not the best place to post this question, but here a lot of
people will see and can direct me to the right place.
I'm using Linux Slackware 10.2 and 11.0, GHC 6.2 and wxWidgets 2.6.X, 2.7.x
I have already tried all kind of combinations but never worked.
I tried: GHC 6.2 , 6.2.
On 16 nov 2006, at 11.46, Jason Dagit wrote:
In #haskell on freenode we had a discussion about isPrefixOf, which is
probably implemented roughly as so:
isPrefixOf [] _ = True
isPrefixOf _ [] = False
isPrefixOf (x:xs) (y:ys) = x == y && isPrefixOf xs ys
Well, this is basically just a zip with a
Bulat Ziganshin gmail.com> writes:
>
> Hello haskell-cafe,
>
> afaik, there are just two good enough libs - wxHaskell and GtkHs. can
> anyone point (or write) detailed comparison of their features? i plan
> to write large GUI program in Haskell and want to select best one.
Putting aside issue
Hi all,
When I try to compile the following in GHC (v 6.6) (with
-fno-monomorphism-restriction -fimplicit-params)
class Configuration a where
thestring:: a -> String
foo c = let { ?c = c } in bar
bar = thestring ?c
I get:
Ambiguous type variable `a' in the constraint:
`Configuration a'
On Wed, 15 Nov 2006 [EMAIL PROTECTED] wrote:
> ...
> I'd be quite happy seeing fromJust removed from the standard
> libraries, or at least tagged `deprecated' or with the stigma
> attached that is rightfully accorded to unsafePerformIO.
However, unsafe* functions are still recommended by Haskell
On 16/11/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
And if we are absolutely positive that the value is (Just x),
we can always write
maybe (assert False undefined) id v
It should be pointed out that Data.Maybe does export a less well-known
function, fromMaybe:
fromMaybe z = mayb
"Jason Dagit" <[EMAIL PROTECTED]> writes:
> Well, this is basically just a zip with a special base case. But you
> can't just write it with zipWith because zipWith stops when it exausts
> either list.
>
> How about we define zipWith'' like this:
> zipWith'' _ [] _ l _ = [l]
> zipWith''
ke, 2006-11-15 kello 13:31 -0800, Greg Buchholz kirjoitti:
> isto wrote:
> ] let t = show (typeOf a)
> ] in case t of
> ] "Double" -> roundDDec d a
> ] "Complex Double" -> roundCDec d a
> Maybe you want type classes instead?
yes, I was blind... Thanks!
isto wrote:
] > isto wrote:
] > ] let t = show (typeOf a)
] > ] in case t of
] > ] "Double" -> roundDDec d a
] > ] "Complex Double" -> roundCDec d a
]
] I'll guess the reason it didn't compile was different
] types at case branches (am I wrong?)
Correct.
] Anyhow, d
On 11/16/06, Eric Willigers <[EMAIL PROTECTED]> wrote:
Bulat Ziganshin gmail.com> writes:
>
> Hello haskell-cafe,
>
> afaik, there are just two good enough libs - wxHaskell and GtkHs. can
> anyone point (or write) detailed comparison of their features? i plan
> to write large GUI program in Has
If anyone is interested, the solution to my problem was to use a type
synonym instead of an isomorphism class.
Pros:
- Not susceptible to the functional dependencies/overlapping
instances/open-world issue
- Very simple (in fact that simplicity migrated into the rest of the system)
Cons:
- Obv
I'm sharing what I think is a novel extension of TypeEq. Please
1) cope with my introduction of the motivating problem
2) inform me if something similar has already been presented
3) criticize the solution
This presentation is quite a simplification of my actual problem/code,
but I'm trying to j
I've recently been looking for some open source software that will
enable me to run a squash/tennis/badminton ladder on the Web. I
haven't found any. So, it's time to write my own. Haskell is my
language of choice. Before I start this project, is there anyone out
there who has written s
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hello fellow squashy,
Sorry I cannot provide any software references for you, but I have had
similar thoughts to yourself. In particular, I keep a track of my win
rate for one of the competitions I play in - but I do this manually.
Each time I do, I th
dmhouse:
> On 16/11/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> >And if we are absolutely positive that the value is (Just x),
> >we can always write
> >maybe (assert False undefined) id v
>
> It should be pointed out that Data.Maybe does export a less well-known
> function, fromMay
dons:
> dmhouse:
> > On 16/11/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> > >And if we are absolutely positive that the value is (Just x),
> > >we can always write
> > >maybe (assert False undefined) id v
> >
> > It should be pointed out that Data.Maybe does export a less well-known
As long as we are doing this, perhaps we should also discourage the
use of (head list)?
-Alex-
__
S. Alexander Jacobson tel:917-770-6565 http://alexjacobson.com
On Fri, 17 Nov 2006, Donald Bruce Stewart wrote:
dons:
dmhouse:
On 1
20 matches
Mail list logo