<cfset thelist = "a,b,c" />
<cfoutput>
<cfloop list="#thelist#" index="a">
<cfloop list="#thelist#" index="b">
<cfloop list="#thelist#" index="c">
#a##b##c#
</cfloop>
</cfloop>
</cfloop>
</cfoutput>
..:.:.:.:.:.:.:.:.:.:.:.
Bobby Hartsfield
http://acoderslife.com
-----Original Message-----
From: Ian Skinner [mailto:[EMAIL PROTECTED]
Sent: Monday, November 27, 2006 4:34 PM
To: CF-Talk
Subject: Challenging Loop problem.
Say I have the following values: A,B,C
How could I programically create the following list in this order?
ACC,ABC,AAC,BAC,CAC,CAB,CAA,CBA,CCA,BCA,ACA,BCA
Or the same thing with the numbers 0,8,16:
16 0 0,16 8 0,16 16 0,8 16 0,0 16 0,0 16 8,0 16 16,0 8 16,0 0 16,8 0 16,16 0
16,16 0 8
Now do the same thing, but with any number of values between 1 and 16.
IE. AB(0 16), ABC(0 8 16), ABCDE(0,4,8,12,16)
I don't even have a clue on how to start.
--------------
Ian Skinner
Web Programmer
BloodSource
www.BloodSource.org
Sacramento, CA
---------
| 1 | |
--------- Binary Soduko
| | |
---------
"C code. C code run. Run code run. Please!"
- Cynthia Dunning
Confidentiality Notice: This message including any
attachments is for the sole use of the intended
recipient(s) and may contain confidential and privileged
information. Any unauthorized review, use, disclosure or
distribution is prohibited. If you are not the
intended recipient, please contact the sender and
delete any copies of this message.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered to your door four
times a year.
http://www.fusionauthority.com/quarterly
Archive:
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:261787
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4