Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Matched pairs represented by triplets??
Message
De
09/03/2003 20:41:50
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Matched pairs represented by triplets??
Divers
Thread ID:
00763480
Message ID:
00763480
Vues:
51
Hi,

I have 10 comma delimited number pairs:
1,2
1,3
1,4
1,5
2,3
2,4
2,5
3,4
3,5
4,5

I have 10 letters. Each of the letters can represent 3 of the of the comma delimited pairs. ie:

a 1,2 1,3 2,3
b 1,2 1,4 2,4
c 1,2 1,5 2,5
d 1,3 1,4 3,4
e 1,3 1,5 3,5
f 1,4 1,5 4,5
g 2,3 2,4 3,4
h 2,3 2,5 3,5
i 2,4 2,5 4,5
j 3,4 3,5 4,5

How do I figure out the least number of letters that will represent all of the comma delimited number pairs. ie: I was able to eye ball the list and figure out that j,i,f,a will do it. But how do you program logic. How about representing the numbers in data tables and using joins and unions. Any takers?

Neil


Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform