def decimal_str_to_int(decimal_string):
int_string = decimal_string.replace('<STR_LIT:.>', '<STR_LIT>')<EOL>int_string = int_string.lstrip('<STR_LIT:0>')<EOL>return int(int_string)<EOL>
Helper to decimal currency string into integers (cents).
WARNING: DO NOT TRY TO DO THIS BY CONVERSION AND MULTIPLICATION,
FLOATING POINT ERRORS ARE NO FUN IN FINANCIAL SYSTEMS.
@param string The amount in currency with full stop decimal separator
@return integer The amount in cents