I don’t know regular expression good enough, and I really badly have to know how to test if an input is a float number with two digits after the dot.
Thanks in advance for the help!
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If x is number:
^\d{2}\.\d{2}$If x is word character
^\w{2}\.\w{2}$Good tools for Regex:
RegExr(Online, i don’t think it is C# Regex dialect but still very useful)Regex Tester(Visual Studio Extension)In my experience Regex is not hard, but the syntax is very unintuitive you really have to memorize it or have a good tool.
On the bright side there are only a couple of instructions/keywords that you need to know but there are not too many for the common usages.
I keep a small test project with Regexes so I dont have to remember them.
In the above regexes the following is done: