title: Why condition if don't working and "skip"?
body: <p>I try writing console app, which print shortest word from the text and if we have several short words, they must also be print. But app print only one word, even I writing 2 identical word. The condition for checking the same words in length does not work for some reason. I know that this can be implemented somehow conveniently, but I did from what I knew.</p>
  <pre><code>static string MinMax(string[] words)
          {
              string[] minValue = new string[] { Convert.ToString(words[0]) };
              int count = 0;
              string minWords = &quot;&quot;;
              for (int i = 0; i &lt; words.Length; i++)
              {
                  if (minValue.Length &gt; words[i].Length)
                  {
                      minValue[0] = words[i]; 
                      for (int e = 0; e &lt; words.Length; e++)
                      {
                          if (minValue[0].Length == words[e].Length) // Проверяет другие слова с такой же длиной и должен добавлять их
                          {
                              minValue[count++] = words[e];
                          }
                          Console.WriteLine(minValue[e]);
                      }
                  }
              }
              for (int i = 0; i &lt; minValue.Length; i++)
              {
                  minWords = minValue[i].ToString();
              }
              //Console.WriteLine(minWords + &quot; = minwords&quot;) ;
              Console.ReadKey();
              return minWords;
          }
      static void Main(string[] args)
      {
          string text = Console.ReadLine();
          string[] words = text.Split(' ', ',', '.', '!', '?', ':', ';', '-', '&quot;', ';');
          string min = MinMax(words);
          Console.WriteLine(min);
          
          Console.ReadKey();
      }
  </code></pre>