<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def replace_markdown_cells(src, dst):
 """ Overwrite markdown cells in notebook object `dst` with corresponding cells in notebook object `src`. """


    # It is an error to attempt markdown replacement if src and dst
    # have different numbers of cells
    if len(src['cells']) != len(dst['cells']):
        raise ValueError('notebooks do not have the same number of cells')

    # Iterate over cells in src
    for n in range(len(src['cells'])):
        # It is an error to attempt markdown replacement if any
        # corresponding pair of cells have different type
        if src['cells'][n]['cell_type'] != dst['cells'][n]['cell_type']:
            raise ValueError('cell number %d of different type in src and dst')
        # If current src cell is a markdown cell, copy the src cell to
        # the dst cell
        if src['cells'][n]['cell_type'] == 'markdown':
            dst['cells'][n]['source'] = src['cells'][n]['source']