Two elements which form more than one compound between them will have compounds whose mass ratio between the two elements are related to each other as a ratio of small whole numbers.
For example, considering two of the carbon oxides: CO and CO2.
In the first, the ratio is 1/1 and in the second 1/2. The ratio between these ratios is a ratio between small whole numbers, or
1/1 : 1/2 = 2:1