s-news
[Top] [All Lists]

Generating a binary series

To: s-news@wubios.wustl.edu
Subject: Generating a binary series
From: "Gareth Williams" <garethdaviswilliams@hotmail.com>
Date: Wed, 13 Sep 2006 08:04:26 -0500

Does anyone know how to generate all combinations of a binary sequence of variable size, e.g.
suppose I wanted a binary sequence of length 3, then I have:
000, 001, 010, 011, 100, 101, 110, 111.

Is there an efficient way to generate this when the length is very large? Thanks again for any help.

Best regards,

Gareth

_________________________________________________________________
All-in-one security and maintenance for your PC. Get a free 90-day trial! http://www.windowsonecare.com/trial.aspx?sc_cid=msn_hotmail


<Prev in Thread] Current Thread [Next in Thread>