Javatpoint Logo
Javatpoint Logo

C# String TrimEnd()

The C# TrimEnd() method is used to remove all trailing occurrences of a set of characters specified in an array from the current String object.

Signature

Parameter

ch: It takes a char array as parameter.

Return

It returns a string.


C# String TrimEnd() Method Example

Output:

Hello C




Please Share

facebook twitter google plus pinterest

Learn Latest Tutorials


B.Tech / MCA