- using System.Linq;
- using System;
- using System.Text;
- using System.Linq;
- namespace forgetCode
- {
- static class Program
- {
- public static void Main(string[] args)
- {
- Console.WriteLine("Enter the string to reverse :");
- string name = Console.ReadLine();
- Console.WriteLine(name.Reverse());
- }
- public static string Reverse(this string input)
- {
- return new string(input.ToCharArray().Reverse().ToArray());
- }
- }
- }