Esempio n. 1
0
 public static bool GetSame(string word1, string word2)
 {
     if (word1.Length != word2.Length)
     {
         return(false);
     }
     return(StringSort.Get_SortedString(word1.ToUpper()) == StringSort.Get_SortedString(word2.ToUpper()));
 }
Esempio n. 2
0
        public static TBL_WORDS Get_Word(TBL_WORDS[] list, string word)
        {
            word = word.ToUpper();
            var result = (from s in list
                          where word.Length == s.WORD_LENGTH &&
                          s.ToString() == StringSort.Get_SortedString(word)
                          select s).FirstOrDefault();

            return(result);
        }
        //----------------------------------------------
        public static void Set_String_Eight()
        {
            string temp = "";

            for (int i = 0; i < 8; i++)
            {
                temp += GetString_One();
            }

            AllList.Eight = StringSort.Get_SortedString(temp);;
        }
Esempio n. 4
0
        public static void Set_NineList()
        {
            var temp = AllList.NineList;

            temp.Clear();
            foreach (string item in Letters.Letter)
            {
                string yeniString = StringSort.Get_SortedString(item + AllList.Eight);
                if (!temp.Contains(yeniString))
                {
                    temp.AddLast(yeniString);
                }
            }
        }
Esempio n. 5
0
 private static void Set_LinkedList(LinkedList <string> temp, LinkedList <string> tempLess)
 {
     temp.Clear();
     foreach (string item in Letters.Letter)
     {
         foreach (var item2 in tempLess)
         {
             string yeniString = StringSort.Get_SortedString(item + item2);
             if (!temp.Contains(yeniString))
             {
                 temp.AddLast(yeniString);
             }
         }
     }
 }
        //-------------------------------------------------------------
        private static LinkedList <string> Get_LinkedList(string str)
        {
            LinkedList <string> temp = new LinkedList <string>();

            for (int i = 0; i < str.Length; i++)
            {
                string tempString = "";

                for (int j = 0; j < str.Length; j++)
                {
                    if (i != j)
                    {
                        tempString += str[j].ToString();
                    }
                }
                tempString = StringSort.Get_SortedString(tempString);
                if (!temp.Contains(tempString))
                {
                    temp.AddLast(tempString);
                }
            }
            return(temp);
        }
Esempio n. 7
0
 public override string ToString()
 {
     return(StringSort.Get_SortedString(WORD));
 }