The chemical formulas C6H12O6 and C3H6O do not describe the same compound, but they do consist of the same types of atoms: carbon (C), hydrogen (H), and oxygen (O). However, the number of each type of atom differs between the two compounds.
C6H12O6 represents glucose, which has 6 carbon, 12 hydrogen, and 6 oxygen atoms.
C3H6O represents acetone (or other compounds, depending on the context), which has 3 carbon, 6 hydrogen, and 1 oxygen atom.
So, they have the same types of atoms (C, H, O), but the numbers of each type of atom are different.
Thus, the best description would be: same types of atoms, different numbers of each type.