title: show the words in a given string that contain two the same consecutive letters
body: <pre><code> class Program
  {
      static void Main(string[] args)
      {
          Console.WriteLine(&quot;Original string: PHP&quot;);
          Console.WriteLine(&quot;Test for consecutive similar letters! &quot; + test(&quot;PHP&quot;));
          Console.WriteLine(&quot;Original string: PHHP&quot;);
          Console.WriteLine(&quot;Test for consecutive similar letters! &quot; + test(&quot;PHHP&quot;));
          Console.WriteLine(&quot;Original string: PHPP&quot;);
          Console.WriteLine(&quot;Test for consecutive similar letters! &quot; + test(&quot;PHPP&quot;));
          Console.WriteLine(&quot;Original string: PPHP&quot;);
          Console.WriteLine(&quot;Test for consecutive similar letters! &quot; + test(&quot;PPHP&quot;));
      }
      public static bool test(string text)
      {
          for (int i = 0; i &lt; text.Length - 1; i++)
          {
              if (text[i] == text[i + 1]) 
                  { 
                    return true; 
                  }
          }
          return false;
      }
  }
  </code></pre>
  <p>}</p>
  <p>I need to make a C# Sharp program to show the words in a given string that contain two the same consecutive letters in windows forms but i only get it in the console version. Anyone can help me to make this a form application?</p>