import Text.Regex

split :: String -> [Int]

split s =
  case matchRegexAll (mkRegex ("[0-9]+")) s of
  Nothing -> []
  Just((_,a,b,_)) -> read a:split b


main :: IO ()
main = getContents >>= print . sum . split