<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def rcm_vertex_order(vertices_resources, nets):
 """A generator which iterates over the vertices in Reverse-Cuthill-McKee order. For use as a vertex ordering for the sequential placer. """

    vertices_neighbours = _get_vertices_neighbours(nets)
    for subgraph_vertices in _get_connected_subgraphs(vertices_resources,
                                                      vertices_neighbours):
        cm_order = _cuthill_mckee(subgraph_vertices, vertices_neighbours)
        for vertex in reversed(cm_order):
            yield vertex