/
(?(DEFINE)
(?<add> \s*\+\s* )
(?<eq> \s*=\s* )
# Remove all zeroes except the last one if the number is 0
(?<zero> (?:0(?=\d))*+ )
# cl: last digit of left operand being 1, cr: last digit of right operand being 1, \d(?:0|\b) check if last digit from result is 0
# there will be carry if cl and cr are set, or cl