Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace ConsoleApp4
- {
- class Program
- {
- public static void Metod(string text)
- {
- int a = text.Length;
- string Ntext = text.Substring(a / 2, a / 2);
- Ntext = Ntext.Replace(" ", string.Empty);
- Console.WriteLine(Ntext);
- }
- public static void Main(string[] args)
- {
- string text;
- text = Console.ReadLine();
- Metod(text);
- Console.ReadKey();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement