Javatpoint Logo
Javatpoint Logo

C# String StartsWith()

The C# StartsWith() method is used to check whether the beginning of this string instance matches the specified string.

Signature

Parameter

str: it is string type parameter which is used to check beginning of string.

Return

It returns boolean value.


C# String StartsWith() Method Example

Output:

False 
True 





Youtube For Videos Join Our Youtube Channel: Join Now

Feedback


Help Others, Please Share

facebook twitter pinterest

Learn Latest Tutorials


Preparation


Trending Technologies


B.Tech / MCA