This question has already been answered:
- Console menu hierarchy 1 answer
tell me what needs to be done so that after performing an action with a string, the program returns to the choice of action?
string str = "Hello guys!"; Console.WriteLine(str); Console.WriteLine("\nWhat we want to do with this string?"); Console.WriteLine("\nInsert - 0; \nRemove - 1; \nReaplace - 2; \nContains - 3; \nExit - 4;\n"); // выбор действия со строкой. int e = Convert.ToInt32(Console.ReadLine()); if (e == 0) { Console.WriteLine("Enter the number of latter: "); // место, в которое нужно вставить символы int i = Convert.ToInt32(Console.ReadLine()); Console.WriteLine("Enter the letter , that we want to insert: "); // символ/ы который/ые вставляем string str1 = Console.ReadLine(); Console.WriteLine(str.Insert(i, "" + str1 + "")); }
do {...} while (I == 0);? - NewViewребятаin English will beguys, not like yours. - Bulson