using System; using System.Collections; using System.Collections.Generic; using System.Linq; using System.Text; namespace vc_test { class Program { static void Main(string[] args) { Program myprograme = new Program(); myprograme.myway(" my name is bill"); Console.ReadKey(); } void myway(string str) { string[] strcoll=new string[]{" "}; string[] strcoll2 = null; strcoll2 = str.Split(strcoll,System .StringSplitOptions .None ); Console.WriteLine("old:{0}", str); str = ""; for (int i = 0; i < strcoll2.Length; i++) { if (!strcoll2[i].Trim().Equals("")) { str+=strcoll2[i].Substring(1)+strcoll2 [i].Substring (0,1) + "ay"; str+=" "; } } Console.WriteLine("now:{0}", str); } } }