I need to remove all dots from text unless they match a pattern [0-9]+.[0-9]+
for example if the following text is my input:
abc. def. 123.45 ... 12.
the output should look like this:
abc def 123.45 12
Thanks
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 the language you are using supports lookarounds you can use this regular expression:
This matches dots that either aren’t preceded by a digit, or aren’t followed by a digit.
Example for C#:
See it working online: ideone