pernod has asked for the wisdom of the Perl Monks concerning the following question:
Esteemed monks,
After reading about the Quantum::Entanglement module, I thought I should give it a try. It might just do exactly what I need for some noisemaking, but my first attempt at using it for anything ended in dismal failure.I used ppm to install the module on my ActiveState installation on a Win XP box. I tried to make a simple example, taken from the above mentioned article. Here's what I got:
#! /usr/bin/perl use strict; use Quantum::Entanglement; my $die = entangle( 1=>1, 1=>2, 1=>3, 1=>4, 1=>5, 1=>6 ); foreach my $i ( 1 .. 5 ) { print "$die "; } print "\n";
My first run of this gave me: 1, 1, 1, 1, 1, which surprised me. I tried again, and got 3, 3, 3, 3, 3
I had expected $die to collapse to different values each time I observed it, but it seems to me that it is only collapsed once during each run. What am I missing here?
pernod
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Problems with Quantum::Entanglement
by Mr. Muskrat (Canon) on Jun 20, 2003 at 16:23 UTC | |
|
Re: Problems with Quantum::Entanglement
by tedrek (Pilgrim) on Jun 20, 2003 at 16:21 UTC | |
|
Re: Problems with Quantum::Entanglement
by bunnyman (Hermit) on Jun 20, 2003 at 16:55 UTC | |
|
Re: Problems with Quantum::Entanglement
by chunlou (Curate) on Jun 21, 2003 at 03:09 UTC | |
|
Re: Problems with Quantum::Entanglement
by zakzebrowski (Curate) on Jun 20, 2003 at 16:18 UTC | |
by tedrek (Pilgrim) on Jun 20, 2003 at 16:24 UTC | |
|
Re: Problems with Quantum::Entanglement
by hossman (Prior) on Jun 21, 2003 at 02:33 UTC |