This question already has an answer here:
- Converting string to int using C# 4 answers
How can I implement a logic similar to the below mentioned code base ?
string a = "1";
string b = "2";
if (a>=b)
{
Console.WriteLine("Greatest is" + a);
}
This is a simple dummy that I created to achieve my required implementation but I am stuck without a way to compare these two integer values which are stored as a string . As shown I have two strings which has two int values stored I simply want to be able to check which one of the two strings is greater than the other
Aucun commentaire:
Enregistrer un commentaire