Javatpoint Logo
Javatpoint Logo

C# String IndexOf()

The C# IndexOf() is used to get index of the specified character present in the string. It returns index as an integer value.

Signature

Parameters

ch: it is a character type parameter.

Return

It returns an integer value.


C# String IndexOf() Method Example

Output:

1
Next TopicC# String Insert()




Please Share

facebook twitter google plus pinterest

Learn Latest Tutorials


B.Tech / MCA