I want to store molecules in memory. These can be simple molecules:
Methane (CH4)
C-H bond-length: 108.7 pm
H-H angle: 109 degrees
But also more complex molecules, like paracetamol (C8H9NO2):

How can I store molecules in memory, including all bond-lengths and angles?
A good idea to store atom-structs in an array? Or is there a better way?
It looks like some kind of graph data structure:
Typically you’d store a graph as an array of nodes (atoms) and an array of edges (bonds). Nodes and edges would both be pointers to structs.
A node (atom) would store the element.
An edge (bond) would store the following fields:
Since it’s not a directed graph, your data structure would consider an edge between A and B to be equivalent to an edge between B and A. That is, for a given pair of atoms, you’d expect your edge array to contain an edge from A to B and never from B to A.