(一)题目描述
将一个字符串str的内容颠倒过来,并输出。str的长度不超过100个字符。
输入
输入包括一行。 第一行输入的字符串。
输出
输出转换好的逆序字符串。
(二)样例输入
输入
I am a student
输出
tneduts a ma I
(三)代码
using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication3
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine(Judge(Console.ReadLine()));
Console.ReadKey();
}
static String Judge(string str)
{
char[] arr = str.ToCharArray();
Array.Reverse(arr);
return new String(arr);
}
}
}