import csv


def csv_to_fasta(csv_path, delimiter=","):
  """Convert a csv-file of the format: <sequence> <name> to a FASTA file."""
  result = ""
  with csv_path.open() as csv_file:
    rd = csv.reader(csv_file, delimiter=delimiter)
    for row in rd:
      result += '> {}\n{}\n'.format(row[1], row[0])
  return result