The work is devoted to methods for comparing and classifying graphs. This trend is known as "graph matching". An overview of metrics for comparing graphs based on the maximum common subgraph is given. A modification of the distance based on the maximum common subgraph, which takes into account the ordering of the vertices, is proposed. It is shown that this function satisfies all the properties of the metric (non-negativity, identity, symmetry, triangle inequality).