yin <[EMAIL PROTECTED]> writes:
> first I have to apologise for my English.
Don't worry about that.
> ./bundle01...
>
> I more apoarches, but no one worked. Now I tried this:
>
>m01_mod :: Int -> Int -> Int
What's m01? You define b01 below:
>b01_mod a b = a mod b
You must type
Jonathan Cast wrote:
> > If you had a version of Haskell without recursive data types you
> > wouldn't be at a loss, because you could always use monads to recreate
> > lists. Maybe "bind" would replace the job of "cons" and "return"
> > would replace "head" or somesuch.
> No. You
I'm working on exercise 6.16 in Thompson's "Haskell; the Craft of
Functional Programming"
My goal for the moment is to call printPicture to see my results:
type Picture = [[Char]]
printPicture :: Picture -> IO ()
printPicture = putStr . concat . map (++"\n")
And everything is encouraging. The r
Dear List Subscribers,
Simon Marlow wrote:
On 30 June 2005 14:36, Dimitry Golubovsky wrote:
It is in CVS now, and I believe will be in 6.4.1
Not planned for 6.4.1, but definitely in 6.6.
I have put those files that work for me in GHC 6.2.2 (Unicode support)
for download. Please read th
Greg Buchholz <[EMAIL PROTECTED]> wrote:
> Here's a question for the Haskell community that I've been
> wrestling with lately. When we say "lists are monads" what does that
> mean? I can see one of two things. First the slightly superficial...
>
> A.) Lists can be made members
Is there any project for extending GHC or any other Haskell compiler
with support to O'Haskell / any object-oriented Haskell extesion? That
could be very useful for improving Haskell interoperability with OO
languages.
Thanks in advance,
Monique Monteiro
--
Moniq
On 2005 July 16 Saturday 11:19, yin wrote:
> I need some testing 'main' function:
>
> ./bundle01...
Your code is close to working. Most likely the detail which gave you trouble
is the syntax for mod. It should be
>b01_mod a b = a `mod` b
Infix operator names in Haskell all use backquotes.
Hello all,
first I have to apologise for my English.
So, I don't fully understand haskells IO, but I need some testing 'main'
function:
./bundle01...
I more apoarches, but no one worked. Now I tried this:
m01_mod :: Int -> Int -> Int
b01_mod a b = a mod b
main = do
(cm
wenduan <[EMAIL PROTECTED]> writes:
> The following function which converts a number represents a sum of money
> in pence didn't work as expected and the result didn't make any sense to me:
>
> penceToString :: Price -> String
> penceToString p =
> let str = show p
>len = length s
The following function which converts a number represents a sum of money
in pence didn't work as expected and the result didn't make any sense to
me:
penceToString :: Price -> String
penceToString p =
let str = show p
len = length str
in
if len ==1 then "0.0" ++ str else
The following function which converts a number represents a sum of money
in pence didn't work as expected and the result didn't make any sense to me:
penceToString :: Price -> String
penceToString p =
let str = show p
len = length str
in
if len ==1 then "0.0" ++ str else
11 matches
Mail list logo