On 10-May-2000, Sverker Nilsson <[EMAIL PROTECTED]> wrote:
>
> Relevance for Haskell would be that you wouldnt be able to fork a
> program written in C into a protected environment (functional
> sandbox?) and know that its result would depend only on its input
> arguments. So you couldnt safely d
Michael Hobbs wrote:
> I believe that the P3 chips come with a noisy diode built-in,
> specifically for the purpose of generating random numbers. You might try
> to find a way to access that little gizmo. (Assuming that you're running
> on a P3.)
Interesting! Do you have any reference for this?
Jan Skibinski wrote:
> Any good idea? First prize: a bottle of something good. :-)
In C, I've sometimes added in the memory location of an arbitrary
variable, just for good measure. But that's not quite as secure in an
open source environment. (Maybe not even that secure in a closed sourc
Mon, 8 May 2000 20:42:10 -0700 (PDT), Ronald J. Legere <[EMAIL PROTECTED]> pisze:
> I have a very simple question. What is the best way to
> convert a float to a double?
> I use fromRational.toRational, and the notes in the prelude
> seem to imply that this is optimized into something sensible
Sven,
That explains it. My tuples are of size 20.
Thanks,
Mike
Deriving works, but GHC currently only contains instance declarations
for tuples up to 5 elements, so you have to write you own boring
instances for larger ones. *yawn*
Cheers,
Sven
--
Sven Panne
Do you derive Show for MyData?
> -Original Message-
> From: Mike Jones [mailto:[EMAIL PROTECTED]]
> Sent: 09 May 2000 05:58
> To: [EMAIL PROTECTED]
> Subject: Showing tuples
>
>
> Hi,
>
> I am having trouble with Show and tuples.
>
> I have a data structure, say:
>
> data MyData = ...
Hi,
I am having trouble with Show and tuples.
I have a data structure, say:
data MyData = ...
And a value, say:
value = (MyData..., MyData..., MyData)
Then try to:
show value
I get a compiler message from ghc 4.05 that says:
No instance for `Show (MyData, MyData, MyData)...
What is th
Mike ... try this ...extend it to however long tuples you have
data MyData = Foo | Bar deriving Show
main = print (Foo,Foo,Foo,Foo,Foo,Foo)
instance (Show tv1, Show tv2, Show tv3, Show tv4, Show tv5 , Show tv6) =>
Show (tv1,tv2,tv3,tv4,
tv5,tv6) where
showsPrec p (v1,v2,v3,v4,v5,v6) =
Mike Jones wrote:
> Yes, I do derive Show for MyData. I was surprised it did not work.
Deriving works, but GHC currently only contains instance declarations
for tuples up to 5 elements, so you have to write you own boring
instances for larger ones. *yawn*
Cheers,
Sven
--
Sven Panne
Chris,
Yes, I do derive Show for MyData. I was surprised it did not work.
Mike
-Original Message-
From: Chris Angus [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, May 09, 2000 12:57 AM
To: 'Mike Jones'; [EMAIL PROTECTED]
Subject: RE: Showing tuples
Do you derive Show for MyData?
> -Or
On Tue, 9 May 2000, Frank Atanassow wrote:
> Jan Skibinski writes:
> >Any good idea? First prize: a bottle of something good. :-)
>
> There is a thing known as an Entropy Gathering Demon (EGD).
>
> >From http://www.lothar.com/tech/crypto/ :
You have been nominated for the first
Jan Skibinski <[EMAIL PROTECTED]> writes:
> Any good idea? First prize: a bottle of something good. :-)
The easiest ought to simply have enough granularity in the
gettimeofday() or equivalent. Sure you can guess the approximate time
in hours or seconds, but can you guess it in micro- or nanose
Jan Skibinski writes:
> Good point. Short of reading some truly random device
> (perhaps ambient temperature fluctuation) this can be always
> theoretically defeated. I can only make life more difficult
> to the attacker by trying to outsmart him algoritmically
> (Or
On Tue, 2 May 2000, Keith Wansbrough wrote:
> Off-topic, I know, but even if this worked as I think you intend,
> it would hardly be random and would certainly be unsuitable for use as a
> nonce. Applying `mkStdGen' to the current time doesn't make it any more
> random! You might as well use
Do you derive Show for MyData?
> -Original Message-
> From: Mike Jones [mailto:[EMAIL PROTECTED]]
> Sent: 09 May 2000 05:58
> To: [EMAIL PROTECTED]
> Subject: Showing tuples
>
>
> Hi,
>
> I am having trouble with Show and tuples.
>
> I have a data structure, say:
>
> data MyData = ..
15 matches
Mail list logo