The example of chalk above was that of a compound. Common salt is made up of sodium atoms and chlorine atoms, which combine into sodium chloride molecule. Water is a compound made up of hydrogen and oxygen atoms. If you take two electrodes and insert in a beaker of water, you will be able to collect oxygen and hydrogen gases at the ends of the two electrodes. Properties of water are entirely different from that of oxygen and hydrogen.
Water is a liquid whereas the elements from which it is made are gaseous.
In a compound, each of the constituent atoms loose their individuality and start displaying a totally new property of the compound formed. The smallest basic unit of a compound that can maintain and display its properties is called a molecule. For a compound to get formed, a chemical reaction between the constituent atoms has to take place . Although there are less than 100 elements or pure substances in nature, there are millions and millions of compounds formed by various permutation and combination of elements. Compounds generally decompose on heating and may either separate into the constituent elements or change into another compound.