1
0
mirror of https://github.com/oliverbooth/X10D synced 2024-11-22 19:28:48 +00:00

Add string.Reverse

This commit is contained in:
Oliver Booth 2020-10-20 14:59:02 +01:00
parent 1601084cb4
commit b424a4b8ec

View File

@ -258,6 +258,16 @@
return builder.ToString();
}
/// <summary>
/// Reverses the current string.
/// </summary>
/// <param name="value">The string to reverse.</param>
/// <returns>A <see cref="string" /> whose characters are that of <paramref name="value" /> in reverse order.</returns>
public static string Reverse(this string value)
{
return string.Join(string.Empty, Enumerable.Reverse(value));
}
/// <summary>
/// Shuffles the characters in the string.
/// </summary>