How to use C# string Compare

2
1



The CSharp String Compare function compares two strings lexicographically . The comparison is based on the Unicode value of each character in the string.

int string.Compare(string str1,string str2)

It returns an Integer indication lexical relationship between the two comprehends

Parameters:

string str1 : Parameter String

string str2 : Parameter String

Returns:

Integer : returns less than zero, zero or greater than zero.

Less than zero : str1 is less than str2

zero : str1 is equal to str2

Greater than zero : str1 is greater than str2

Moreover, you should also visit our:

Website:
Blog:
Shop:
FbPage:
Twitter:
Google+ :
YouTube:
Email: help@theengineeringprojects.com
Skype: theenggprojects
Mobile / WhatsApp : +92-332-6062060

Thanks for Watching.

Nguồn:https://wijstaanvooronzegrondrechten.org/

2 COMMENTS

LEAVE A REPLY

Please enter your comment!
Please enter your name here