def content_to_md(content, ref_count, faulty_pdfs):
    """ Returns the content (reference list for each PDF file) in a markdown formated string

    Keyword arguments:
    content -- a dict with each key being a PDF filepath and reference list (str) as value
    ref_count -- a dict with each key being a PDF filepath and reference count as value
    faulty_pdfs -- a list of PDF files, either without references or with parsing issues
    """
    content_md = ''
    for key, value in content.items():
        content_md += ('### File: ' + key + ' (reference count: ' + str(ref_count[key]) +
                       ')\n```\n' + value + '```\n')
    if len(faulty_pdfs) != 0:
        content_md += ('\n :x: Could not find reference list for PDF files: ' + ' '.join(faulty_pdfs))
    return content_md