Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re^2: Generate all unique combinations of 1 and 0 using specified length of "0"-string and count of 1's

by marioroy (Parson)
on Dec 29, 2020 at 05:01 UTC ( #11125914=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    print "$_\n" for GenUniStrings(9, 25);
    
  2. or download this
    my ($numOnes, $strLen) = (9, 25);
    
    ...
    00000010
    00000001
    00000000
    
  3. or download this
    use strict;
    use warnings;
    ...
    } @input_data;
    
    print "$_\n" for @strings;
    
  4. or download this
    use strict;
    use warnings;
    ...
            MCE::relay { print "$_\n" for @strings; };
        }
    )->run;
    
  5. or download this
    $ time perl serial.pl >/dev/null
    
    ...
    user  0m7.067s
    sys   0m0.507s
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11125914]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (3)
As of 2022-12-09 01:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?