Human: How to use regex with optional characters in python? Assistant: 
Here is some code to match regex pattern '(\\d+(\\.\\d+)?)' with string '3434.35353'

print(re.match('(\\d+(\\.\\d+)?)', '3434.35353').group(1))

#Warning: this code generation is experimental. Please inspect the code for any bugs before executing.