The application of graph theory in chemical and molecular structure research far exceeds people’s expectations, and it has recently grown exponentially. In the molecular graph, atoms are represented by vertices and bonded by edges. In this report, we study the M-polynomial of line graph of \(HAC_{5}C_{6}C_{7}[p,q]\) and recover many degree-based topological indices from it.