M
Maxime
Hi i have a fonction who check word in dictionnaire but when i use ToString he convert my word of 4 char in a string of 13 char ? Why
string[] dic; // Dictionnairy in memory
public void isDic(char[] aWord)
{
Array.Sort(aWord);
for(int i=0;i<dic.Length;i++)
{
if(aWord.Length == dic.Length)
{
char[] cWord = dic.ToCharArray();
Array.Sort(cWord);
if(aWord.ToString().CompareTo(cWord.ToString())==0)
{
lOut.Text += dic + " ";
}
}
}
lOut.Text += " FIN";
}
Thanks Max
string[] dic; // Dictionnairy in memory
public void isDic(char[] aWord)
{
Array.Sort(aWord);
for(int i=0;i<dic.Length;i++)
{
if(aWord.Length == dic.Length)
{
char[] cWord = dic.ToCharArray();
Array.Sort(cWord);
if(aWord.ToString().CompareTo(cWord.ToString())==0)
{
lOut.Text += dic + " ";
}
}
}
lOut.Text += " FIN";
}
Thanks Max