def split_tables(text):
  """Splits tables from the text if they exist."""
  tables = RE_TABLE.findall(text)
  text = RE_TABLE.sub("", text)
  return text, tables
Splits tables from the text if they exist.
language/fruit/wiki_utils.py