From the given paragraph of text, write a program to match
the strings of format “Any number of numerals followed by
an underscore followed by any number of alphabets"
ex:123_abc
(Note:using regular expressions)
Answer Posted / kp
private void RegExp(string input)
{
string s = input;
Regex regexp = new Regex("^[0-9]*_[A-Za-z]*$");
if(regexp.IsMatch(input))
Console.WriteLine("Matched");
else
Console.WriteLine("Not Match");
}
Is This Answer Correct ? | 19 Yes | 2 No |
Post New Answer View All Answers
How is session id generated?
What is data cache in sql server?
What is css in asp.net?
Explain what are webservices?
How to create events for a control?
Is viewstate secure?
Can you set the session out time manually?
What are the Types of authentications in IIS
Is asp.net and .net same?
Which browsers support the xmlhttprequest object?
How can you ensure a permanent cookie?
What is http request and response?
How would ASP and ASP.NET applications run at the same time on the same server?
What is difference between Lambda Expression and LINQ in ASP.NET?
Where is session cookies stored?