108
C# String EndsWith()
The C# EndsWith() method is used to check whether the specified string matches the end of this string or not. If the specified string is found at the end of this string, it returns true otherwise false.
Signature
Parameters
str: it is a string object which is used to check the whether a specified string ends with it.
Return
It returns boolean value either true or false.
C# String EndsWith() Method Example
Output:
True False
Next TopicC# String Equals()