import re input_text = 'This is a test number +223/34 and this a real number 2333. The email is test@gmail.com and the website is www.test.com.' print( re.sub(r'[-+]?\b\d+(?:[.,+/*-]\d+)*\b', '', input_text) )
Standard input is empty
This is a test number and this a real number . The email is test@gmail.com and the website is www.test.com.