How do I extract roundUp(...) using regex (or some other derivative) from the following possible permutations:
[[[ roundUp( 10.0 ) ]]]
[[[ roundUp( 10.0 + 2.0 ) ]]]
[[[ roundUp( (10.0 * 2.0) + 2.0 ) ]]]
[[[ 10.0 + roundUp( (10.0 * 2.0) + 2.0 ) ]]]
[[[ 10.0 + roundUp( (10.0 * 2.0) + 2.0 ) + 20.0 ]]]
The reason I’m asking is I would like to replace roundUp(...) with math.ceil((...)*100)/100.0 in my code but I’m not to sure how to do it because of the chance brackets being used multiple times to help with operator precedence
This is python, why don’t you just rebind the name
roundUp: