We can work out the formula of carbon dioxide as follows :
1. Carbon dioxide is a compound made up of carbon and oxygen element. So, first we write down the symbols of carbon (C) and oxygen (O).
2. The valency of carbon is 4 and the valency of oxygen is 2. So, below the symbol C we write 4 and below the symbol O we write 2.
3. We now cross-over the valencies of C and O atoms. The formula becomes `C_(2)O_(4)`. This formula contains 2 carbon atoms and 4 oxygen atoms having a common factor of 2. So, dividing this formula by the common factor of 2, we get the simplest formula `CO_(2)`. Thus, the formula of carbon dioxide is `CO_(2)`.