in reply to Re: Function over all letters in a string
in thread Function over all letters in a string
#!/usr/bin/perl use strict; use warnings; my $c = 0; while (1) { $c ++; my $r = rand; die "Failed ($r) after $c attempts.\n" if substr ($r, 2) =~ /\D/; } __END__ Failed (1.13079331747201195e-05) after 17507 attempts.
Abigail
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Function over all letters in a string
by Aristotle (Chancellor) on Dec 01, 2003 at 17:06 UTC | |
by Abigail-II (Bishop) on Dec 01, 2003 at 17:47 UTC | |
by Aristotle (Chancellor) on Dec 01, 2003 at 18:11 UTC |